@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class Condition extends Object implements Serializable, Cloneable, StructuredPojo
A JSON string which you can use to limit the event bus permissions you are granting to only accounts that fulfill the
condition. Currently, the only supported condition is membership in a certain Amazon Web Services organization. The
string must contain Type
, Key
, and Value
fields. The Value
field
specifies the ID of the Amazon Web Services organization. Following is an example value for Condition
:
'{"Type" : "StringEquals", "Key": "aws:PrincipalOrgID", "Value": "o-1234567890"}'
Constructor and Description |
---|
Condition() |
Modifier and Type | Method and Description |
---|---|
Condition |
clone() |
boolean |
equals(Object obj) |
String |
getKey()
Specifies the key for the condition.
|
String |
getType()
Specifies the type of condition.
|
String |
getValue()
Specifies the value for the key.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setKey(String key)
Specifies the key for the condition.
|
void |
setType(String type)
Specifies the type of condition.
|
void |
setValue(String value)
Specifies the value for the key.
|
String |
toString()
Returns a string representation of this object.
|
Condition |
withKey(String key)
Specifies the key for the condition.
|
Condition |
withType(String type)
Specifies the type of condition.
|
Condition |
withValue(String value)
Specifies the value for the key.
|
public void setType(String type)
Specifies the type of condition. Currently the only supported value is StringEquals
.
type
- Specifies the type of condition. Currently the only supported value is StringEquals
.public String getType()
Specifies the type of condition. Currently the only supported value is StringEquals
.
StringEquals
.public Condition withType(String type)
Specifies the type of condition. Currently the only supported value is StringEquals
.
type
- Specifies the type of condition. Currently the only supported value is StringEquals
.public void setKey(String key)
Specifies the key for the condition. Currently the only supported key is aws:PrincipalOrgID
.
key
- Specifies the key for the condition. Currently the only supported key is aws:PrincipalOrgID
.public String getKey()
Specifies the key for the condition. Currently the only supported key is aws:PrincipalOrgID
.
aws:PrincipalOrgID
.public Condition withKey(String key)
Specifies the key for the condition. Currently the only supported key is aws:PrincipalOrgID
.
key
- Specifies the key for the condition. Currently the only supported key is aws:PrincipalOrgID
.public void setValue(String value)
Specifies the value for the key. Currently, this must be the ID of the organization.
value
- Specifies the value for the key. Currently, this must be the ID of the organization.public String getValue()
Specifies the value for the key. Currently, this must be the ID of the organization.
public Condition withValue(String value)
Specifies the value for the key. Currently, this must be the ID of the organization.
value
- Specifies the value for the key. Currently, this must be the ID of the organization.public String toString()
toString
in class Object
Object.toString()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.