public class Dataset extends Object implements Serializable
A collection of data for an identity pool. An identity pool can have multiple datasets. A dataset is per identity and can be general or associated with a particular entity in an application (like a saved game). Datasets are automatically created if they don't exist. Data is synced by dataset, and a dataset can hold up to 1MB of key-value pairs.
Constructor and Description |
---|
Dataset() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
Date |
getCreationDate()
Date.
|
String |
getDatasetName()
A string of up to 128 characters.
|
Long |
getDataStorage()
Total size in bytes of the records in this dataset.
|
String |
getIdentityId()
A name-spaced GUID (for example,
us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito.
|
String |
getLastModifiedBy()
The device that made the last change to this dataset.
|
Date |
getLastModifiedDate()
Date when the dataset was last modified.
|
Long |
getNumRecords()
Number of records in this dataset.
|
int |
hashCode() |
void |
setCreationDate(Date creationDate)
Date.
|
void |
setDatasetName(String datasetName)
A string of up to 128 characters.
|
void |
setDataStorage(Long dataStorage)
Total size in bytes of the records in this dataset.
|
void |
setIdentityId(String identityId)
A name-spaced GUID (for example,
us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito.
|
void |
setLastModifiedBy(String lastModifiedBy)
The device that made the last change to this dataset.
|
void |
setLastModifiedDate(Date lastModifiedDate)
Date when the dataset was last modified.
|
void |
setNumRecords(Long numRecords)
Number of records in this dataset.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
Dataset |
withCreationDate(Date creationDate)
Date.
|
Dataset |
withDatasetName(String datasetName)
A string of up to 128 characters.
|
Dataset |
withDataStorage(Long dataStorage)
Total size in bytes of the records in this dataset.
|
Dataset |
withIdentityId(String identityId)
A name-spaced GUID (for example,
us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito.
|
Dataset |
withLastModifiedBy(String lastModifiedBy)
The device that made the last change to this dataset.
|
Dataset |
withLastModifiedDate(Date lastModifiedDate)
Date when the dataset was last modified.
|
Dataset |
withNumRecords(Long numRecords)
Number of records in this dataset.
|
public String getIdentityId()
Constraints:
Length: 1 - 50
Pattern: [\w-]+:[0-9a-f-]+
public void setIdentityId(String identityId)
Constraints:
Length: 1 - 50
Pattern: [\w-]+:[0-9a-f-]+
identityId
- A name-spaced GUID (for example,
us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito. GUID generation is unique within a region.public Dataset withIdentityId(String identityId)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 50
Pattern: [\w-]+:[0-9a-f-]+
identityId
- A name-spaced GUID (for example,
us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
Cognito. GUID generation is unique within a region.public String getDatasetName()
Constraints:
Length: 1 - 128
Pattern: [a-zA-Z0-9_.:-]+
public void setDatasetName(String datasetName)
Constraints:
Length: 1 - 128
Pattern: [a-zA-Z0-9_.:-]+
datasetName
- A string of up to 128 characters. Allowed characters are a-z, A-Z,
0-9, '_' (underscore), '-' (dash), and '.' (dot).public Dataset withDatasetName(String datasetName)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 128
Pattern: [a-zA-Z0-9_.:-]+
datasetName
- A string of up to 128 characters. Allowed characters are a-z, A-Z,
0-9, '_' (underscore), '-' (dash), and '.' (dot).public Date getCreationDate()
public void setCreationDate(Date creationDate)
creationDate
- Date.public Dataset withCreationDate(Date creationDate)
Returns a reference to this object so that method calls can be chained together.
creationDate
- Date.public Date getLastModifiedDate()
public void setLastModifiedDate(Date lastModifiedDate)
lastModifiedDate
- Date when the dataset was last modified.public Dataset withLastModifiedDate(Date lastModifiedDate)
Returns a reference to this object so that method calls can be chained together.
lastModifiedDate
- Date when the dataset was last modified.public String getLastModifiedBy()
public void setLastModifiedBy(String lastModifiedBy)
lastModifiedBy
- The device that made the last change to this dataset.public Dataset withLastModifiedBy(String lastModifiedBy)
Returns a reference to this object so that method calls can be chained together.
lastModifiedBy
- The device that made the last change to this dataset.public Long getDataStorage()
public void setDataStorage(Long dataStorage)
dataStorage
- Total size in bytes of the records in this dataset.public Dataset withDataStorage(Long dataStorage)
Returns a reference to this object so that method calls can be chained together.
dataStorage
- Total size in bytes of the records in this dataset.public Long getNumRecords()
public void setNumRecords(Long numRecords)
numRecords
- Number of records in this dataset.public Dataset withNumRecords(Long numRecords)
Returns a reference to this object so that method calls can be chained together.
numRecords
- Number of records in this dataset.public String toString()
toString
in class Object
Object.toString()
Copyright © 2014. All rights reserved.