private void setStartServerFields ( HandshakerReq . Builder req , ByteBuffer inBytes ) { ServerHandshakeParameters serverParameters = ServerHandshakeParameters . newBuilder ( ) . addRecordProtocols ( RECORD_PROTOCOL ) . build ( ) ; StartServerHandshakeReq . Builder startServerReq = StartServerHandshakeReq . newBuilder ( ) . addApplicationProtocols ( APPLICATION_PROTOCOL ) . putHandshakeParameters ( HandshakeProtocol . ALTS . getNumber ( ) , serverParameters ) . setInBytes ( ByteString . copyFrom ( inBytes . duplicate ( ) ) ) ; if ( handshakerOptions . getRpcProtocolVersions ( ) != null ) { startServerReq . setRpcVersions ( handshakerOptions . getRpcProtocolVersions ( ) ) ; } req . setServerStart ( startServerReq ) ; }
Sets the start server fields for the passed handshake request .