public class ContextEntry extends Object implements Serializable, Cloneable
Contains information about a condition context key. It includes the
name of the key and specifies the value (or values, if the context key
supports multiple values) to use in the simulation. This information
is used when evaluating the Condition elements of the
input policies.
This data type is used as an input parameter to SimulatePolicy
.
| Constructor and Description |
|---|
ContextEntry() |
| Modifier and Type | Method and Description |
|---|---|
ContextEntry |
clone() |
boolean |
equals(Object obj) |
String |
getContextKeyName()
The full name of a condition context key, including the service
prefix.
|
String |
getContextKeyType()
The data type of the value (or values) specified in the
ContextKeyValues parameter. |
List<String> |
getContextKeyValues()
The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a
Condition element in an input policy. |
int |
hashCode() |
void |
setContextKeyName(String contextKeyName)
The full name of a condition context key, including the service
prefix.
|
void |
setContextKeyType(ContextKeyTypeEnum contextKeyType)
The data type of the value (or values) specified in the
ContextKeyValues parameter. |
void |
setContextKeyType(String contextKeyType)
The data type of the value (or values) specified in the
ContextKeyValues parameter. |
void |
setContextKeyValues(Collection<String> contextKeyValues)
The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a
Condition element in an input policy. |
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
ContextEntry |
withContextKeyName(String contextKeyName)
The full name of a condition context key, including the service
prefix.
|
ContextEntry |
withContextKeyType(ContextKeyTypeEnum contextKeyType)
The data type of the value (or values) specified in the
ContextKeyValues parameter. |
ContextEntry |
withContextKeyType(String contextKeyType)
The data type of the value (or values) specified in the
ContextKeyValues parameter. |
ContextEntry |
withContextKeyValues(Collection<String> contextKeyValues)
The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a
Condition element in an input policy. |
ContextEntry |
withContextKeyValues(String... contextKeyValues)
The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a
Condition element in an input policy. |
public String getContextKeyName()
aws:SourceIp or
s3:VersionId.
Constraints:
Length: 5 - 256
aws:SourceIp or
s3:VersionId.public void setContextKeyName(String contextKeyName)
aws:SourceIp or
s3:VersionId.
Constraints:
Length: 5 - 256
contextKeyName - The full name of a condition context key, including the service
prefix. For example, aws:SourceIp or
s3:VersionId.public ContextEntry withContextKeyName(String contextKeyName)
aws:SourceIp or
s3:VersionId.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 5 - 256
contextKeyName - The full name of a condition context key, including the service
prefix. For example, aws:SourceIp or
s3:VersionId.public List<String> getContextKeyValues()
Condition element in an input policy.Condition element in an input policy.public void setContextKeyValues(Collection<String> contextKeyValues)
Condition element in an input policy.contextKeyValues - The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a Condition element in an input policy.public ContextEntry withContextKeyValues(String... contextKeyValues)
Condition element in an input policy.
NOTE: This method appends the values to the existing list (if
any). Use setContextKeyValues(java.util.Collection) or withContextKeyValues(java.util.Collection) if you want to override
the existing values.
Returns a reference to this object so that method calls can be chained together.
contextKeyValues - The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a Condition element in an input policy.public ContextEntry withContextKeyValues(Collection<String> contextKeyValues)
Condition element in an input policy.
Returns a reference to this object so that method calls can be chained together.
contextKeyValues - The value (or values, if the condition context key supports multiple
values) to provide to the simulation for use when the key is
referenced by a Condition element in an input policy.public String getContextKeyType()
ContextKeyValues parameter.
Constraints:
Allowed Values: string, stringList, numeric, numericList, boolean, booleanList, ip, ipList, binary, binaryList, date, dateList
ContextKeyValues parameter.ContextKeyTypeEnumpublic void setContextKeyType(String contextKeyType)
ContextKeyValues parameter.
Constraints:
Allowed Values: string, stringList, numeric, numericList, boolean, booleanList, ip, ipList, binary, binaryList, date, dateList
contextKeyType - The data type of the value (or values) specified in the
ContextKeyValues parameter.ContextKeyTypeEnumpublic ContextEntry withContextKeyType(String contextKeyType)
ContextKeyValues parameter.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: string, stringList, numeric, numericList, boolean, booleanList, ip, ipList, binary, binaryList, date, dateList
contextKeyType - The data type of the value (or values) specified in the
ContextKeyValues parameter.ContextKeyTypeEnumpublic void setContextKeyType(ContextKeyTypeEnum contextKeyType)
ContextKeyValues parameter.
Constraints:
Allowed Values: string, stringList, numeric, numericList, boolean, booleanList, ip, ipList, binary, binaryList, date, dateList
contextKeyType - The data type of the value (or values) specified in the
ContextKeyValues parameter.ContextKeyTypeEnumpublic ContextEntry withContextKeyType(ContextKeyTypeEnum contextKeyType)
ContextKeyValues parameter.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: string, stringList, numeric, numericList, boolean, booleanList, ip, ipList, binary, binaryList, date, dateList
contextKeyType - The data type of the value (or values) specified in the
ContextKeyValues parameter.ContextKeyTypeEnumpublic String toString()
toString in class ObjectObject.toString()public ContextEntry clone()
Copyright © 2015. All rights reserved.