public void write(org.apache.thrift.protocol.TProtocol oprot, RolePrincipalGrant struct) throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.roleName != null) {
        oprot.writeFieldBegin(ROLE_NAME_FIELD_DESC);
        oprot.writeString(struct.roleName);
        oprot.writeFieldEnd();
      }
      if (struct.principalName != null) {
        oprot.writeFieldBegin(PRINCIPAL_NAME_FIELD_DESC);
        oprot.writeString(struct.principalName);
        oprot.writeFieldEnd();
      }
      if (struct.principalType != null) {
        oprot.writeFieldBegin(PRINCIPAL_TYPE_FIELD_DESC);
        oprot.writeI32(struct.principalType.getValue());
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(GRANT_OPTION_FIELD_DESC);
      oprot.writeBool(struct.grantOption);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(GRANT_TIME_FIELD_DESC);
      oprot.writeI32(struct.grantTime);
      oprot.writeFieldEnd();
      if (struct.grantorName != null) {
        oprot.writeFieldBegin(GRANTOR_NAME_FIELD_DESC);
        oprot.writeString(struct.grantorName);
        oprot.writeFieldEnd();
      }
      if (struct.grantorPrincipalType != null) {
        oprot.writeFieldBegin(GRANTOR_PRINCIPAL_TYPE_FIELD_DESC);
        oprot.writeI32(struct.grantorPrincipalType.getValue());
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise
standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/RolePrincipalGrant.java