Package com.openai.models.moderations
Class ModerationTextInput
-
- All Implemented Interfaces:
public final class ModerationTextInput
An object describing text to classify.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final class
ModerationTextInput.Builder
A builder for ModerationTextInput.
-
Method Summary
Modifier and Type Method Description final String
text()
A string of text to classify. final JsonValue
_type()
Always text
.final JsonField<String>
_text()
Returns the raw JSON value of text. final Map<String, JsonValue>
_additionalProperties()
final ModerationTextInput.Builder
toBuilder()
final ModerationTextInput
validate()
final Boolean
isValid()
Boolean
equals(Object other)
Integer
hashCode()
String
toString()
final static ModerationTextInput.Builder
builder()
Returns a mutable builder for constructing an instance of ModerationTextInput. -
-
Method Detail
-
_type
final JsonValue _type()
Always
text
.Expected to always return the following:
JsonValue.from("text")
However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
_text
final JsonField<String> _text()
Returns the raw JSON value of text.
Unlike text, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final ModerationTextInput.Builder toBuilder()
-
validate
final ModerationTextInput validate()
-
builder
final static ModerationTextInput.Builder builder()
Returns a mutable builder for constructing an instance of ModerationTextInput.
The following fields are required:
.text()
-
-
-
-