JavaScript is disabled on your browser.
Skip navigation links

AWS SDK for Java 1.x API Reference - 1.12.795

We announced the upcoming end-of-support for AWS SDK for Java (v1). We recommend that you migrate to AWS SDK for Java v2. For dates, additional details, and information on how to migrate, please refer to the linked announcement.
com.amazonaws.services.dynamodbv2.document

Class PrimaryKey



  • public class PrimaryKey
    extends Object 
    Used to represent a primary key that has one or multiple key components.
    • Constructor Detail

      • PrimaryKey

        public PrimaryKey()
      • PrimaryKey

        public PrimaryKey(KeyAttribute... components)
        Constructs with the specified key components.
      • PrimaryKey

        public PrimaryKey(String hashKeyName,
         Object hashKeyValue)
        Constructs with a hash key.
      • PrimaryKey

        public PrimaryKey(String hashKeyName,
         Object hashKeyValue,
         String rangeKeyName,
         Object rangeKeyValue)
        Constructs with a hash key and a range key.
    • Method Detail

      • getComponents

        public Collection<KeyAttribute> getComponents()
        Returns all the key components of this primary key.
      • getComponentNameSet

        public Set<String> getComponentNameSet()
        Returns all the key component names of this primary key as a set.
      • hasComponent

        public boolean hasComponent(String attrName)
        Returns true if this primary has the specified key attribute name; false otherwise.
      • addComponents

        public PrimaryKey addComponents(KeyAttribute... components)
        Add one or multiple key components to this primary key. Note adding a key component with the same name as that of an existing one would overwrite and become a single key component instead of two.
      • addComponent

        public PrimaryKey addComponent(String keyAttributeName,
         Object keyAttributeValue)
        Add a key component to this primary key. Note adding a key component with the same name as that of an existing one would overwrite and become a single key component instead of two.
Skip navigation links

AltStyle によって変換されたページ (->オリジナル) /