public void setOutboundInterface(SipURI outboundInterface) { if(outboundInterface == null) { throw new NullPointerException("outbound Interface param shouldn't be null"); } List<SipURI> list = this.sipFactoryImpl.getSipNetworkInterfaceManager().getOutboundInterfaces(); SipURI networkInterface = null; for(SipURI networkInterfaceURI : list) { if(networkInterfaceURI.equals(outboundInterface)) { networkInterface = networkInterfaceURI; break; } } if(networkInterface == null) throw new IllegalArgumentException("Network interface for " + outboundInterface + " not found"); this.outboundInterface = networkInterface; }
public void setOutboundInterface(SipURI outboundInterface) { checkSessionValidity(); if(outboundInterface == null) { throw new NullPointerException("outbound Interface param shouldn't be null"); } List<SipURI> list = proxy.getSipFactoryImpl().getSipNetworkInterfaceManager().getOutboundInterfaces(); SipURI networkInterface = null; for(SipURI networkInterfaceURI : list) { if(networkInterfaceURI.equals(outboundInterface)) { networkInterface = networkInterfaceURI; break; } } if(networkInterface == null) throw new IllegalArgumentException("Network interface for " + outboundInterface + " not found"); this.outboundInterface = networkInterface; }
public void setOutboundInterface(SipURI outboundInterface) { if(!isValid()) { throw new IllegalStateException("the session has been invalidated"); } if(outboundInterface == null) { throw new NullPointerException("parameter is null"); } List<SipURI> list = sipFactory.getSipNetworkInterfaceManager().getOutboundInterfaces(); SipURI networkInterface = null; for(SipURI networkInterfaceURI : list) { if(networkInterfaceURI.equals(outboundInterface)) { networkInterface = networkInterfaceURI; break; } } if(networkInterface == null) throw new IllegalArgumentException("Network interface for " + outboundInterface + " not found"); this.outboundInterface = outboundInterface.toString(); if(outboundInterface.getTransportParam() != null) { this.transport = outboundInterface.getTransportParam(); } }