/** * Check whether the given return code is a provisional response. * * @param rc * the return code * @return true when the code is provisional */ private boolean isProvisional(ReturnCode rc) { final int rval = rc.getValue(); return ((99 < rval) && (rval < 200)); }
/** * Check whether the given return code is a provisional response. * * @param rc * the return code * @return true when the code is provisional */ private boolean isProvisional(ReturnCode rc) { final int rval = rc.getValue(); return ((99 < rval) && (rval < 200)); }
/** * Check whether the given return code is a provisional response. * * @param rc * the return code * @return true when the code is provisional */ private boolean isProvisional(ReturnCode rc) { final int rval = rc.getValue(); return ((99 < rval) && (rval < 200)); }
public static int encode(byte[] destination,int offset,ReturnCode returnCode) { return StringFunctions.encodeInt(destination,offset,returnCode.getValue()); } }
public void processMgcpResponseEvent(JainMgcpResponseEvent event) { //NotifucationRequest response expected only NotificationRequestResponse evt = (NotificationRequestResponse) event; switch (event.getReturnCode().getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY : break; } }
public void processMgcpResponseEvent(JainMgcpResponseEvent event) { //NotifucationRequest response expected only NotificationRequestResponse evt = (NotificationRequestResponse) event; switch (event.getReturnCode().getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY : break; } }
public static int encode(byte[] destination,int offset,ReturnCode returnCode) { return StringFunctions.encodeInt(destination,offset,returnCode.getValue()); } }
@Override public String encode(JainMgcpResponseEvent event) { NotificationRequestResponse response = (NotificationRequestResponse) event; ReturnCode returnCode = response.getReturnCode(); String encodedEvent = (new StringBuffer().append(returnCode.getValue()).append(SINGLE_CHAR_SPACE).append( response.getTransactionHandle()).append(SINGLE_CHAR_SPACE).append(returnCode.getComment()) .append(NEW_LINE)).toString(); return encodedEvent; }
public String encode(JainMgcpResponseEvent event) { EndpointConfigurationResponse response = (EndpointConfigurationResponse) event; ReturnCode returnCode = response.getReturnCode(); StringBuffer s = new StringBuffer(); s.append(returnCode.getValue()).append(SINGLE_CHAR_SPACE).append(response.getTransactionHandle()).append( SINGLE_CHAR_SPACE).append(returnCode.getComment()).append(NEW_LINE); return s.toString(); }
public String encode(JainMgcpResponseEvent event) { ModifyConnectionResponse response = (ModifyConnectionResponse) event; ReturnCode returnCode = response.getReturnCode(); StringBuffer s = new StringBuffer(); s.append(returnCode.getValue()).append(SINGLE_CHAR_SPACE).append(response.getTransactionHandle()).append( SINGLE_CHAR_SPACE).append(returnCode.getComment()).append(NEW_LINE); if (response.getLocalConnectionDescriptor() != null) { s.append(NEW_LINE).append(response.getLocalConnectionDescriptor()); } return s.toString(); }
@Override public String encode(JainMgcpResponseEvent event) { StringBuffer s = new StringBuffer(); s.append(event.getReturnCode().getValue()).append(SINGLE_CHAR_SPACE).append(event.getTransactionHandle()) .append(SINGLE_CHAR_SPACE).append(event.getReturnCode().getComment()).append(NEW_LINE); return s.toString(); // return event.getReturnCode().getValue() + " " + // event.getTransactionHandle() + " " // + event.getReturnCode().getComment() + "\n"; }
private void response(final Object message) { final NotificationRequestResponse response = (NotificationRequestResponse) message; final ReturnCode code = response.getReturnCode(); if (!Transaction_Executed_Normally.equals(code)) { final int value = code.getValue(); fail(value); } }
public String encode(JainMgcpResponseEvent event) { DeleteConnectionResponse response = (DeleteConnectionResponse) event; ReturnCode returnCode = response.getReturnCode(); StringBuffer s = new StringBuffer(); s.append(returnCode.getValue()).append(SINGLE_CHAR_SPACE).append(response.getTransactionHandle()).append( SINGLE_CHAR_SPACE).append(returnCode.getComment()).append(NEW_LINE); if (response.getConnectionParms() != null) { s.append(response.getConnectionParms()).append(NEW_LINE); } return s.toString(); }
public void processMgcpResponseEvent(JainMgcpResponseEvent event) { switch (event.getReturnCode().getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY: SignalDetectorEventImpl oc = new SignalDetectorEventImpl(null, SignalDetectorEvent.FLUSH_BUFFER_COMPLETED, true); fireEvent(oc); System.out.println("DONE FLUSH BUFFER=======================>"); break; default : break; } }
public void processMgcpResponseEvent(JainMgcpResponseEvent event) { switch (event.getReturnCode().getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY: SignalDetectorEventImpl oc = new SignalDetectorEventImpl(null, SignalDetectorEvent.FLUSH_BUFFER_COMPLETED, true); fireEvent(oc); System.out.println("DONE FLUSH BUFFER=======================>"); break; default : break; } }
public void onNotificationRequestResponse(NotificationRequestResponse event, ActivityContextInterface aci) { logger.info("onNotificationRequestResponse"); ReturnCode status = event.getReturnCode(); switch (status.getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY: logger.info("The Announcement should have been started"); break; default: ReturnCode rc = event.getReturnCode(); logger.severe("RQNT failed. Value = " + rc.getValue() + " Comment = " + rc.getComment()); // TODO : Send DLCX to MMS. Send BYE to UA break; } }
public void processMgcpResponseEvent(JainMgcpResponseEvent event) { switch (event.getReturnCode().getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY: parent.releaseStop(); SignalDetectorEventImpl oc = new SignalDetectorEventImpl(null, SignalDetectorEvent.RECEIVE_SIGNALS_COMPLETED, true); oc.setQualifier(ResourceEvent.STOPPED); fireEvent(oc); System.out.println("DONE STOP=======================>"); break; default : break; } }
public void processMgcpResponseEvent(JainMgcpResponseEvent event) { switch (event.getReturnCode().getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY: parent.releaseStop(); SignalDetectorEventImpl oc = new SignalDetectorEventImpl(null, SignalDetectorEvent.RECEIVE_SIGNALS_COMPLETED, true); oc.setQualifier(ResourceEvent.STOPPED); fireEvent(oc); System.out.println("DONE STOP=======================>"); break; default : break; } }
protected void onJainMgcpResponseEvent(JainMgcpResponseEvent message, ActorRef self, ActorRef sender) { if (this.destroying.get()) { ReturnCode returnCode = message.getReturnCode(); if (ReturnCode.TRANSACTION_EXECUTED_NORMALLY == returnCode.getValue()) { broadcast(new EndpointStateChanged(EndpointState.DESTROYED)); } else { logger.error("Could not destroy endpoint " + this.id.toString() + ". Return Code: " + returnCode.toString()); broadcast(new EndpointStateChanged(EndpointState.FAILED)); } } }
public void onNotificationRequestResponse(NotificationRequestResponse event, ActivityContextInterface aci) { ReturnCode status = event.getReturnCode(); switch (status.getValue()) { case ReturnCode.TRANSACTION_EXECUTED_NORMALLY: log.info("########## VOICE MAIL SBB: RQNT executed properly. TXID: "+event.getTransactionHandle()+" ##########"); break; default: ReturnCode rc = event.getReturnCode(); log.info("########## VOICE MAIL SBB: RQNT failed, terminating call. TXID: "+event.getTransactionHandle()+" ##########"); sendByeRequest(); break; } }