/// <exception cref="System.IO.IOException"/>
        public override void ReadFields(DataInput @in)
        {
            DataInputStream dis = (DataInputStream)@in;

            byte[] buffer = IOUtils.ToByteArray(dis);
            proto = YarnSecurityTestClientAMTokenProtos.ClientToAMTokenIdentifierForTestProto
                    .ParseFrom(buffer);
        }
 public ClientToAMTokenIdentifierForTest(ClientToAMTokenIdentifier tokenIdentifier
                                         , string message)
 {
     YarnSecurityTestClientAMTokenProtos.ClientToAMTokenIdentifierForTestProto.Builder
         builder = YarnSecurityTestClientAMTokenProtos.ClientToAMTokenIdentifierForTestProto
                   .NewBuilder();
     builder.SetAppAttemptId(tokenIdentifier.GetProto().GetAppAttemptId());
     builder.SetClientName(tokenIdentifier.GetProto().GetClientName());
     builder.SetMessage(message);
     proto = ((YarnSecurityTestClientAMTokenProtos.ClientToAMTokenIdentifierForTestProto
               )builder.Build());
 }