Class BetaResponse.Moderation.Input.Error
-
- All Implemented Interfaces:
public final class BetaResponse.Moderation.Input.ErrorAn error produced while attempting moderation for the response input or output.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classBetaResponse.Moderation.Input.Error.BuilderA builder for Error.
-
Method Summary
Modifier and Type Method Description final Stringcode()The error code. final Stringmessage()The error message. final JsonValue_type()The object type, which was always errorfor moderation failures.final JsonField<String>_code()Returns the raw JSON value of code. final JsonField<String>_message()Returns the raw JSON value of message. final Map<String, JsonValue>_additionalProperties()final BetaResponse.Moderation.Input.Error.BuildertoBuilder()final BetaResponse.Moderation.Input.Errorvalidate()Validates that the types of all values in this object match their expected types recursively. final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static BetaResponse.Moderation.Input.Error.Builderbuilder()Returns a mutable builder for constructing an instance of Error. -
-
Method Detail
-
_type
final JsonValue _type()
The object type, which was always
errorfor moderation failures.Expected to always return the following:
JsonValue.from("error")However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
_code
final JsonField<String> _code()
Returns the raw JSON value of code.
Unlike code, this method doesn't throw if the JSON field has an unexpected type.
-
_message
final JsonField<String> _message()
Returns the raw JSON value of message.
Unlike message, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final BetaResponse.Moderation.Input.Error.Builder toBuilder()
-
validate
final BetaResponse.Moderation.Input.Error validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
builder
final static BetaResponse.Moderation.Input.Error.Builder builder()
Returns a mutable builder for constructing an instance of Error.
The following fields are required:
.code() .message()
-
-
-
-