validate method

dynamic validate()

Implementation

validate() {
  // check for required fields
  // check that fields of type enum have valid values
  if (isSetRole() && !HostRole.VALID_VALUES.contains(role)) {
    throw new TProtocolError(TProtocolErrorType.UNKNOWN,
        "The field 'role' has been assigned the invalid value $role");
  }
}