public class GlobalSecondaryIndex
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
Represents the properties of a global secondary index.
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
indexName
The name of the global secondary index.
|
private java.util.List<KeySchemaElement> |
keySchema
The complete key schema for a global secondary index, which consists of
one or more pairs of attribute names and key types:
|
private Projection |
projection |
private ProvisionedThroughput |
provisionedThroughput |
Constructor and Description |
---|
GlobalSecondaryIndex() |
Modifier and Type | Method and Description |
---|---|
GlobalSecondaryIndex |
clone() |
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getIndexName()
The name of the global secondary index.
|
java.util.List<KeySchemaElement> |
getKeySchema()
The complete key schema for a global secondary index, which consists of
one or more pairs of attribute names and key types:
|
Projection |
getProjection() |
ProvisionedThroughput |
getProvisionedThroughput() |
int |
hashCode() |
void |
setIndexName(java.lang.String indexName)
The name of the global secondary index.
|
void |
setKeySchema(java.util.Collection<KeySchemaElement> keySchema)
The complete key schema for a global secondary index, which consists of
one or more pairs of attribute names and key types:
|
void |
setProjection(Projection projection) |
void |
setProvisionedThroughput(ProvisionedThroughput provisionedThroughput) |
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
GlobalSecondaryIndex |
withIndexName(java.lang.String indexName)
The name of the global secondary index.
|
GlobalSecondaryIndex |
withKeySchema(java.util.Collection<KeySchemaElement> keySchema)
The complete key schema for a global secondary index, which consists of
one or more pairs of attribute names and key types:
|
GlobalSecondaryIndex |
withKeySchema(KeySchemaElement... keySchema)
The complete key schema for a global secondary index, which consists of
one or more pairs of attribute names and key types:
|
GlobalSecondaryIndex |
withProjection(Projection projection) |
GlobalSecondaryIndex |
withProvisionedThroughput(ProvisionedThroughput provisionedThroughput) |
private java.lang.String indexName
The name of the global secondary index. The name must be unique among all other indexes on this table.
private java.util.List<KeySchemaElement> keySchema
The complete key schema for a global secondary index, which consists of one or more pairs of attribute names and key types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
private Projection projection
private ProvisionedThroughput provisionedThroughput
public void setIndexName(java.lang.String indexName)
The name of the global secondary index. The name must be unique among all other indexes on this table.
indexName
- The name of the global secondary index. The name must be unique
among all other indexes on this table.public java.lang.String getIndexName()
The name of the global secondary index. The name must be unique among all other indexes on this table.
public GlobalSecondaryIndex withIndexName(java.lang.String indexName)
The name of the global secondary index. The name must be unique among all other indexes on this table.
indexName
- The name of the global secondary index. The name must be unique
among all other indexes on this table.public java.util.List<KeySchemaElement> getKeySchema()
The complete key schema for a global secondary index, which consists of one or more pairs of attribute names and key types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
public void setKeySchema(java.util.Collection<KeySchemaElement> keySchema)
The complete key schema for a global secondary index, which consists of one or more pairs of attribute names and key types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
keySchema
- The complete key schema for a global secondary index, which
consists of one or more pairs of attribute names and key
types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
public GlobalSecondaryIndex withKeySchema(KeySchemaElement... keySchema)
The complete key schema for a global secondary index, which consists of one or more pairs of attribute names and key types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
NOTE: This method appends the values to the existing list (if
any). Use setKeySchema(java.util.Collection)
or
withKeySchema(java.util.Collection)
if you want to override the
existing values.
keySchema
- The complete key schema for a global secondary index, which
consists of one or more pairs of attribute names and key
types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
public GlobalSecondaryIndex withKeySchema(java.util.Collection<KeySchemaElement> keySchema)
The complete key schema for a global secondary index, which consists of one or more pairs of attribute names and key types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
keySchema
- The complete key schema for a global secondary index, which
consists of one or more pairs of attribute names and key
types:
HASH
- partition key
RANGE
- sort key
The partition key of an item is also known as its hash attribute. The term "hash attribute" derives from DynamoDB' usage of an internal hash function to evenly distribute data items across partitions, based on their partition key values.
The sort key of an item is also known as its range attribute. The term "range attribute" derives from the way DynamoDB stores items with the same partition key physically close together, in sorted order by the sort key value.
public void setProjection(Projection projection)
projection
- public Projection getProjection()
public GlobalSecondaryIndex withProjection(Projection projection)
projection
- public void setProvisionedThroughput(ProvisionedThroughput provisionedThroughput)
provisionedThroughput
- public ProvisionedThroughput getProvisionedThroughput()
public GlobalSecondaryIndex withProvisionedThroughput(ProvisionedThroughput provisionedThroughput)
provisionedThroughput
- public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public GlobalSecondaryIndex clone()
clone
in class java.lang.Object