@Test public void testCreateReset() { CoAPResponse reset = resp.createReset(); Assert.assertArrayEquals(reset.getToken(), resp.getToken()); assertEquals(reset.getSocketAddress(), resp.getSocketAddress()); assertEquals(reset.getMessageId(), resp.getMessageId()); assertEquals(reset.getMessageType(), CoAPMessageType.RESET); }
public CoAPResponse createReset() { CoAPResponse resp = new CoAPResponse(1, CoAPMessageType.RESET, CoAPResponseCode.EMPTY, getMessageId(), getToken()); resp.setSocketAddress(getSocketAddress()); return resp; }
CoAPResponse extends CoAPMessage { public CoAPResponse createReset() { CoAPResponse resp = new CoAPResponse(1, CoAPMessageType.RESET, CoAPResponseCode.EMPTY, getMessageId(), getToken()); resp.setSocketAddress(getSocketAddress()); return resp; } }
CoAPResponse extends CoAPMessage { public CoAPResponse createReset() { CoAPResponse resp = new CoAPResponse(1, CoAPMessageType.RESET, CoAPResponseCode.EMPTY, getMessageId(), getToken()); resp.setSocketAddress(getSocketAddress()); return resp; } CoAPResponse(int version, CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId, byte[] token);  CoAPResponse(int version, CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId);  CoAPResponse(CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId, byte[] token);  CoAPResponse(CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId);  CoAPResponse(int version, CoAPRequest request, CoAPMessageType messageType, CoAPResponseCode responseCode); }
CoAPResponse extends CoAPMessage { public CoAPResponse createReset() { CoAPResponse resp = new CoAPResponse(1, CoAPMessageType.RESET, CoAPResponseCode.EMPTY, getMessageId(), getToken()); resp.setSocketAddress(getSocketAddress()); return resp; } CoAPResponse(int version, CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId, byte[] token);  CoAPResponse(int version, CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId);  CoAPResponse(CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId, byte[] token);  CoAPResponse(CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId);  CoAPResponse(int version, CoAPRequest request, CoAPMessageType messageType, CoAPResponseCode responseCode); @Override CoAPResponseCode getCode(); CoAPResponse createAcknowledgement(); CoAPResponse createReset(); boolean isCacheable(); }
CoAPResponse extends CoAPMessage { public CoAPResponse createReset() { CoAPResponse resp = new CoAPResponse(1, CoAPMessageType.RESET, CoAPResponseCode.EMPTY, getMessageId(), getToken()); resp.setSocketAddress(getSocketAddress()); return resp; } CoAPResponse(int version, CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId, byte[] token);  CoAPResponse(int version, CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId);  CoAPResponse(CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId, byte[] token);  CoAPResponse(CoAPMessageType messageType, CoAPResponseCode responseCode, int messageId);  CoAPResponse(int version, CoAPRequest request, CoAPMessageType messageType, CoAPResponseCode responseCode); @Override CoAPResponseCode getCode(); CoAPResponse createAcknowledgement(); CoAPResponse createReset(); boolean isCacheable();  }