Package javax.sip.header

Examples of javax.sip.header.ViaHeader


       
      CallIdHeader callId = provider.getNewCallId();     
      CSeqHeader cSeq = headerFactory.createCSeqHeader(1l, Request.INVITE);
      FromHeader from = headerFactory.createFromHeader(fromAddress, "1234");
      ToHeader to = headerFactory.createToHeader(addressFactory.createAddress("server@"+host+":"+SERVER_PORT), null);
      ViaHeader via = ((ListeningPointImpl)provider.getListeningPoint(testProtocol)).getViaHeader();
      via.setRPort();
      List vias = Arrays.asList(via);     
      MaxForwardsHeader maxForwards = headerFactory.createMaxForwardsHeader(10);
       
        URI requestURI = addressFactory.createURI("sip:test@"+host+":"+SERVER_PORT);
        Request request = messageFactory.createRequest(requestURI, Request.INVITE, callId, cSeq, from, to, vias, maxForwards);
View Full Code Here


                // Create ViaHeaders

                ArrayList viaHeaders = new ArrayList();
                int port = provider.getListeningPoint("udp").getPort();

                ViaHeader viaHeader = headerFactory.createViaHeader(myAddress,
                        port, "udp", null);

                // add via headers
                viaHeaders.add(viaHeader);
View Full Code Here

                    toUser, peerHostPort);

            // Create ViaHeaders

            ArrayList viaHeaders = new ArrayList();
            ViaHeader viaHeader = headerFactory
                    .createViaHeader(host, sipProvider.getListeningPoint(
                            transport).getPort(),
                            transport, null);

            // add via headers
View Full Code Here

        sipUri.setTransportParam(Shootme.transport);
        Address address = addressFactory.createAddress("client1", sipUri);
        RouteHeader rheader = headerFactory.createRouteHeader(address);

        newRequest.addFirst(rheader);
        ViaHeader viaHeader = headerFactory.createViaHeader(host, this.port, "udp", null);
        newRequest.addFirst(viaHeader);
        ClientTransaction ct1 = sipProviders.get(Shootme.transport).getNewClientTransaction(newRequest);
        sipUri = addressFactory.createSipURI("proxy", "127.0.0.1");
        address = addressFactory.createAddress("proxy", sipUri);
        sipUri.setPort(5070);
View Full Code Here

                // Create ViaHeaders

                ArrayList viaHeaders = new ArrayList();
                String ipAddress = udpListeningPoint.getIPAddress();
                ViaHeader viaHeader = headerFactory.createViaHeader(ipAddress,
                        sipProvider.getListeningPoint(transport).getPort(),
                        transport, null);

                // add via headers
                viaHeaders.add(viaHeader);
View Full Code Here

                    + "t=0 0\r\n" + "m=audio 6022 RTP/AVP 0 4 18\r\n"
                    + "a=rtpmap:0 PCMU/8000\r\n" + "a=rtpmap:4 G723/8000\r\n"
                    + "a=rtpmap:18 G729A/8000\r\n" + "a=ptime:20\r\n";
            // Create ViaHeaders
            ArrayList viaHeaders = new ArrayList();
            ViaHeader viaHeader = headerFactory.createViaHeader(myAddress,
                    listeningPoint.getPort(), transport, null);

            // add via headers
            viaHeaders.add(viaHeader);
            Request request = messageFactory.createRequest(requestURI,
View Full Code Here

                // Create ViaHeaders

                ArrayList viaHeaders = new ArrayList();
                String ipAddress = udpListeningPoint.getIPAddress();
                ViaHeader viaHeader = headerFactory.createViaHeader(ipAddress,
                        sipProvider.getListeningPoint(transport).getPort(),
                        transport, null);

                // add via headers
                viaHeaders.add(viaHeader);
View Full Code Here

        //requestURI.setSecure( true );

        // Create ViaHeaders

        ArrayList viaHeaders = new ArrayList();
        ViaHeader viaHeader =
            headerFactory.createViaHeader(
                "127.0.0.1",
                port,
                transport,
                null);
View Full Code Here

            // Create ViaHeaders

            ArrayList viaHeaders = new ArrayList();

            ViaHeader viaHeader = headerFactory.createViaHeader("127.0.0.1",
                    port, transport, null);

            // add via headers
            viaHeaders.add(viaHeader);
View Full Code Here

            //requestURI.setSecure( true );

            // Create ViaHeaders

           ArrayList viaHeaders = new ArrayList();
           ViaHeader viaHeader =
                headerFactory.createViaHeader(
                    "127.0.0.1",
                    port,
                    transport,
                    null);
View Full Code Here

TOP

Related Classes of javax.sip.header.ViaHeader

Copyright © 2018 www.massapicom. 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.