public MessageBuffer < ChannelBuffer > getLoginBuffer ( InetSocketAddress localUDPAddress ) throws Exception { ChannelBuffer loginBuffer ; ChannelBuffer credentials = NettyUtils . writeStrings ( username , password , connectionKey ) ; if ( null != localUDPAddress ) { ChannelBuffer udpAddressBuffer = NettyUtils . writeSocketAddress ( localUDPAddress ) ; loginBuffer = ChannelBuffers . wrappedBuffer ( credentials , udpAddressBuffer ) ; } else { loginBuffer = credentials ; } return new NettyMessageBuffer ( loginBuffer ) ; }
Creates the appropriate login buffer using username password connectionkey and the local address to which the UDP channel is bound .