@Test public void testSerializeExtensionContent() { msg.setExtensionType(extensionType.getValue()); msg.setExtensionLength(extensionLength); msg.setCertificateTypes(CertificateType.toByteArray(certificateTypes)); if (certificateTypesLength != null) { msg.setCertificateTypesLength(certificateTypesLength); } else { msg.setCertificateTypesLength(null); } msg.setIsClientMessage(isClientState); assertArrayEquals(expectedBytes, serializer.serialize()); }
@Override public byte[] serializeExtensionContent() { if (msg.getCertificateTypesLength() != null) { appendInt(msg.getCertificateTypesLength().getValue(), ExtensionByteLength.CERTIFICATE_TYPE_TYPE_LENGTH); } appendBytes(msg.getCertificateTypes().getValue()); return getAlreadySerialized(); }
CertificateTypeExtensionSerializer extends ExtensionSerializer<CertificateTypeExtensionMessage> { @Override public byte[] serializeExtensionContent() { if (msg.getCertificateTypesLength() != null) { appendInt(msg.getCertificateTypesLength().getValue(), ExtensionByteLength.CERTIFICATE_TYPE_TYPE_LENGTH); } appendBytes(msg.getCertificateTypes().getValue()); return getAlreadySerialized(); } }
CertificateTypeExtensionSerializer extends ExtensionSerializer<CertificateTypeExtensionMessage> { @Override public byte[] serializeExtensionContent() { if (msg.getCertificateTypesLength() != null) { appendInt(msg.getCertificateTypesLength().getValue(), ExtensionByteLength.CERTIFICATE_TYPE_TYPE_LENGTH); } appendBytes(msg.getCertificateTypes().getValue()); return getAlreadySerialized(); } CertificateTypeExtensionSerializer(CertificateTypeExtensionMessage message); }
CertificateTypeExtensionSerializer extends ExtensionSerializer<CertificateTypeExtensionMessage> { @Override public byte[] serializeExtensionContent() { if (msg.getCertificateTypesLength() != null) { appendInt(msg.getCertificateTypesLength().getValue(), ExtensionByteLength.CERTIFICATE_TYPE_TYPE_LENGTH); } appendBytes(msg.getCertificateTypes().getValue()); return getAlreadySerialized(); } CertificateTypeExtensionSerializer(CertificateTypeExtensionMessage message); @Override byte[] serializeExtensionContent(); }
CertificateTypeExtensionSerializer extends ExtensionSerializer<CertificateTypeExtensionMessage> { @Override public byte[] serializeExtensionContent() { if (msg.getCertificateTypesLength() != null) { appendInt(msg.getCertificateTypesLength().getValue(), ExtensionByteLength.CERTIFICATE_TYPE_TYPE_LENGTH); } appendBytes(msg.getCertificateTypes().getValue()); return getAlreadySerialized(); } CertificateTypeExtensionSerializer(CertificateTypeExtensionMessage message); @Override byte[] serializeExtensionContent();  }