类 PutItemRequest


  • public class PutItemRequest
    extends AbstractBceRequest
    Represents the input of a PutItem operation.
    • 构造器详细资料

      • PutItemRequest

        public PutItemRequest()
        Constructs a new PutItemRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.
      • PutItemRequest

        public PutItemRequest​(String name)
        Constructs a new PutItemRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.
        参数:
        name - The name of the table to contain the item.
    • 方法详细资料

      • getTableName

        public String getTableName()
        Get the name of the table to contain the item.

        Constraints:
        Length: 3 - 32
        Pattern: [a-zA-Z0-9_.-]+

        返回:
        The name of the table to contain the item.
      • setTableName

        public void setTableName​(String tableName)
        Set the name of the table to contain the item.

        Constraints:
        Length: 3 - 32
        Pattern: [a-zA-Z0-9_.-]+

        参数:
        tableName - The name of the table to contain the item.
      • withTableName

        public PutItemRequest withTableName​(String tableName)
        Set the name of the table to contain the item.

        Constraints:
        Length: 3 - 32
        Pattern: [a-zA-Z0-9_.-]+

        参数:
        tableName - The name of the table to contain the item.
        返回:
        Returns a reference to the object so that method calls can be chained together.
      • withItem

        public PutItemRequest withItem​(Map<String,​AttributeValue> item)
        Set the Item object to be put in in table. Returns a reference to this object so that method calls can be chained together.
        参数:
        item - An container of attribute name/value pairs. Only the primary key attributes are required; you can optionally provide other attribute name-value pairs for the item.

        You must provide all of the attributes for the primary key. For example, with a hash type primary key, you only need to provide the hash attribute. For a hash-and-range type primary key, you must provide both the hash attribute and the range attribute.

        If you specify any attributes that are part of an key, then the data types for those attributes must match those of the schema in the table's attribute definition.

        返回:
        A reference to this updated object so that method calls can be chained together.
      • setItem

        public void setItem​(Map<String,​AttributeValue> item)
        Set the Item object to be put in in table.
        参数:
        item - An container of attribute name/value pairs. Only the primary key attributes are required; you can optionally provide other attribute name-value pairs for the item.

        You must provide all of the attributes for the primary key. For example, with a hash type primary key, you only need to provide the hash attribute. For a hash-and-range type primary key, you must provide both the hash attribute and the range attribute.

        If you specify any attributes that are part of an key, then the data types for those attributes must match those of the schema in the table's attribute definition.

      • getItem

        public Map<String,​AttributeValue> getItem()
        Get the Item objects to be put in in table.
        返回:
        An map container of attribute name/value pairs.
      • toString

        public String toString()
        Return a string representation of request information.
        覆盖:
        toString 在类中 Object
        返回:
        A string representation of request information.