Examples of removeParameter()


Examples of javax.servlet.sip.SipURI.removeParameter()

    contact = request.getAddressHeader("Contact");
    uri = (SipURI) contact.getURI();
    contact.setDisplayName("Bob");
    uri.setHost("nexcom.fr");
    uri.setPort(5062);
    uri.removeParameter("transport");
    uri.setUser("bob");
    assertEquals("Bob <sip:bob@nexcom.fr:5062>", contact.toString());   
  }
 
 
View Full Code Here

Examples of javax.servlet.sip.SipURI.removeParameter()

  {
    URI target = uri.clone();
    if (target.isSipURI())
    {
      SipURI sipUri = (SipURI) target;
      sipUri.removeParameter("method");
      Iterator<String> it = sipUri.getHeaderNames();
      while (it.hasNext())
      {
        it.remove();
      }
View Full Code Here

Examples of javax.servlet.sip.TelURL.removeParameter()

    TelURL orig = new TelURLImpl("tel:+3398648;user=phone");
    TelURL readOnly = new ReadOnlyTelURL((TelURL) orig.clone());
   
    assertEquals(orig, readOnly);
    try { readOnly.setParameter("foo", "bar"); fail();} catch (IllegalStateException e) {}
    try { readOnly.removeParameter("user");   fail();} catch (IllegalStateException e) {}
    assertEquals(orig, readOnly);
    assertEquals(readOnly, orig);
    assertEquals(orig.toString(), readOnly.toString());
    URI clone = (URI) readOnly.clone();
    clone.setParameter("a", "b");
View Full Code Here

Examples of javax.servlet.sip.URI.removeParameter()

    URI orig = new URIImpl("http://www.nexcom.fr;user=me");
    URI readOnly = new ReadOnlyURI((URI) orig.clone());
   
    assertEquals(orig, readOnly);
    try { readOnly.setParameter("foo", "bar"); fail();} catch (IllegalStateException e) {}
    try { readOnly.removeParameter("user");   fail();} catch (IllegalStateException e) {}
    assertEquals(orig, readOnly);
    assertEquals(readOnly, orig);
    assertEquals(orig.toString(), readOnly.toString());
    URI clone = (URI) readOnly.clone();
    clone.setParameter("a", "b");
View Full Code Here

Examples of javax.servlet.sip.URI.removeParameter()

  {
    URI uri = URIFactory.parseURI("http://www.nexcom.fr;param1=a");
    assertEquals("http://www.nexcom.fr;param1=a", uri.toString());
    uri.setParameter("param2", "b");
    assertEquals("a", uri.getParameter("param1"));
    uri.removeParameter("param1");
    assertEquals("b", uri.getParameter("param2"));
    assertNull(uri.getParameter("param1"));
    assertEquals("http://www.nexcom.fr;param2=b", uri.toString());
  }
}
View Full Code Here

Examples of javax.sip.address.SipURI.removeParameter()

                    jiplet.debug("While proxying a request, we canonicalized"
                            + " the request-URI");
                while (iterator != null && iterator.hasNext())
                {
                    String name = (String) iterator.next();
                    requestSipURI.removeParameter(name);
                }
            }

            // We fork only INVITE
            if (uris.size() > 1 && !msg.getMethod().equals(Request.INVITE))
View Full Code Here

Examples of javax.sip.header.ContentTypeHeader.removeParameter()

            //           
            ContentTypeHeader contentTypeHeader = (ContentTypeHeader) clonedRequest
                    .getHeader(ContentTypeHeader.NAME);
            if (contentTypeHeader != null)
            {
                contentTypeHeader.removeParameter("msgr");
            }

            // if the proxy has been reset, do not send the to tag
            if (proxy.isReset() == true)
            {
View Full Code Here

Examples of javax.sip.header.FromHeader.removeParameter()

              sentResponses ++;
              try {
                Response okResponse = messageFactory.createResponse(180,
                    request);
                FromHeader from = (FromHeader) okResponse.getHeader(FromHeader.NAME);
                from.removeParameter("tag");
                Address address = addressFactory.createAddress("Shootme <sip:"
                    + myAddress + ":" + myPort + ">");
                ContactHeader contactHeader = headerFactory
                .createContactHeader(address);
                ToHeader toHeader = (ToHeader) okResponse.getHeader(ToHeader.NAME);
View Full Code Here

Examples of javax.sip.header.FromHeader.removeParameter()

            }
            try {
                Response okResponse = messageFactory.createResponse(200,
                        request);
                FromHeader from = (FromHeader) okResponse.getHeader(FromHeader.NAME);
                from.removeParameter("tag");
                Address address = addressFactory.createAddress("Shootme <sip:"
                        + myAddress + ":" + myPort + ">");
                ContactHeader contactHeader = headerFactory
                        .createContactHeader(address);
                ToHeader toHeader = (ToHeader) okResponse.getHeader(ToHeader.NAME);
View Full Code Here

Examples of javax.sip.header.FromHeader.removeParameter()

            }
            try {
                Response okResponse = messageFactory.createResponse(200,
                        request);
                FromHeader from = (FromHeader) okResponse.getHeader(FromHeader.NAME);
                from.removeParameter("tag");
                Address address = addressFactory.createAddress("Shootme <sip:"
                        + myAddress + ":" + myPort + ">");
                ContactHeader contactHeader = headerFactory
                        .createContactHeader(address);
                ToHeader toHeader = (ToHeader) okResponse.getHeader(ToHeader.NAME);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.