Package org.apache.hadoop.yarn.proto.YarnServerCommonServiceProtos

Examples of org.apache.hadoop.yarn.proto.YarnServerCommonServiceProtos.RegisterNodeManagerResponseProto.writeTo()


  public static RegisterNodeManagerResponse serDe(RegisterNodeManagerResponse orig) throws Exception {
    RegisterNodeManagerResponsePBImpl asPB = (RegisterNodeManagerResponsePBImpl)orig;
    RegisterNodeManagerResponseProto proto = asPB.getProto();
    ByteArrayOutputStream out = new ByteArrayOutputStream();
    proto.writeTo(out);
    ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray());
    RegisterNodeManagerResponseProto.Builder cp = RegisterNodeManagerResponseProto.newBuilder();
    cp.mergeFrom(in);
    return new RegisterNodeManagerResponsePBImpl(cp.build());
  }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.