DHEServerKeyExchangeHandler extends ServerKeyExchangeHandler<DHEServerKeyExchangeMessage> { @Override public DHEServerKeyExchangeSerializer getSerializer(DHEServerKeyExchangeMessage message) { return new DHEServerKeyExchangeSerializer(message, tlsContext.getChooser().getSelectedProtocolVersion()); } DHEServerKeyExchangeHandler(TlsContext tlsContext); @Override DHEServerKeyExchangeParser getParser(byte[] message, int pointer); @Override DHEServerKeyExchangePreparator getPreparator(DHEServerKeyExchangeMessage message); @Override DHEServerKeyExchangeSerializer getSerializer(DHEServerKeyExchangeMessage message); @Override void adjustTLSContext(DHEServerKeyExchangeMessage message);  }
@Test public void testGetSerializer() { assertTrue(handler.getSerializer(new DHEServerKeyExchangeMessage()) instanceof DHEServerKeyExchangeSerializer); }