@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class GuardrailTopic extends Object implements Serializable, Cloneable, StructuredPojo
Details about topics for the guardrail to identify and deny.
This data type is used in the following API operations:
Constructor and Description |
---|
GuardrailTopic() |
Modifier and Type | Method and Description |
---|---|
GuardrailTopic |
clone() |
boolean |
equals(Object obj) |
String |
getDefinition()
A definition of the topic to deny.
|
List<String> |
getExamples()
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
|
String |
getName()
The name of the topic to deny.
|
String |
getType()
Specifies to deny the topic.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setDefinition(String definition)
A definition of the topic to deny.
|
void |
setExamples(Collection<String> examples)
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
|
void |
setName(String name)
The name of the topic to deny.
|
void |
setType(String type)
Specifies to deny the topic.
|
String |
toString()
Returns a string representation of this object.
|
GuardrailTopic |
withDefinition(String definition)
A definition of the topic to deny.
|
GuardrailTopic |
withExamples(Collection<String> examples)
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
|
GuardrailTopic |
withExamples(String... examples)
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
|
GuardrailTopic |
withName(String name)
The name of the topic to deny.
|
GuardrailTopic |
withType(GuardrailTopicType type)
Specifies to deny the topic.
|
GuardrailTopic |
withType(String type)
Specifies to deny the topic.
|
public void setName(String name)
The name of the topic to deny.
name
- The name of the topic to deny.public String getName()
The name of the topic to deny.
public GuardrailTopic withName(String name)
The name of the topic to deny.
name
- The name of the topic to deny.public void setDefinition(String definition)
A definition of the topic to deny.
definition
- A definition of the topic to deny.public String getDefinition()
A definition of the topic to deny.
public GuardrailTopic withDefinition(String definition)
A definition of the topic to deny.
definition
- A definition of the topic to deny.public List<String> getExamples()
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
public void setExamples(Collection<String> examples)
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
examples
- A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the
topic.public GuardrailTopic withExamples(String... examples)
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
NOTE: This method appends the values to the existing list (if any). Use
setExamples(java.util.Collection)
or withExamples(java.util.Collection)
if you want to override
the existing values.
examples
- A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the
topic.public GuardrailTopic withExamples(Collection<String> examples)
A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the topic.
examples
- A list of prompts, each of which is an example of a prompt that can be categorized as belonging to the
topic.public void setType(String type)
Specifies to deny the topic.
type
- Specifies to deny the topic.GuardrailTopicType
public String getType()
Specifies to deny the topic.
GuardrailTopicType
public GuardrailTopic withType(String type)
Specifies to deny the topic.
type
- Specifies to deny the topic.GuardrailTopicType
public GuardrailTopic withType(GuardrailTopicType type)
Specifies to deny the topic.
type
- Specifies to deny the topic.GuardrailTopicType
public String toString()
toString
in class Object
Object.toString()
public GuardrailTopic clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.