/** * Creates a new binding response message. * * @param transactionId The ID of the transaction. * @param errorCode The code for the error. * @param reasonPhrase The reason description. */ public BindingErrorResponse(final UUID transactionId, final int errorCode, final String reasonPhrase) { super(transactionId, StunMessageType.BINDING_ERROR_RESPONSE, createAttributes(errorCode, reasonPhrase)); }
private static Map<StunAttributeType, StunAttribute> createAttributes( final int errorCode, final String reasonPhrase) { final StunAttribute error = new ErrorCodeAttribute(errorCode, reasonPhrase); return createAttributes(error); }