Constructor and Description |
---|
ItemModel.Builder()
Constructor with parameters for the required properties of
ItemModel . |
Modifier and Type | Method and Description |
---|---|
ItemModel |
build() |
ItemModel.Builder |
setCached(java.lang.Boolean cached)
The status that indicates whether the library item is on disk or not.
|
ItemModel.Builder |
setContentVersion(java.lang.String contentVersion)
The version of the file content list of this library item.
|
ItemModel.Builder |
setCreationTime(java.util.Calendar creationTime)
The date and time when this library item was created.
|
ItemModel.Builder |
setDescription(java.lang.String description)
A human-readable description for this library item.
|
ItemModel.Builder |
setId(java.lang.String id)
A unique identifier for this library item.
|
ItemModel.Builder |
setLastModifiedTime(java.util.Calendar lastModifiedTime)
The date and time when the metadata for this library item was last changed.
|
ItemModel.Builder |
setLastSyncTime(java.util.Calendar lastSyncTime)
The date and time when this library item was last synchronized.
|
ItemModel.Builder |
setLibraryId(java.lang.String libraryId)
The identifier of the
LibraryModel to which this item
belongs. |
ItemModel.Builder |
setMetadataVersion(java.lang.String metadataVersion)
A version number for the metadata of this library item.
|
ItemModel.Builder |
setName(java.lang.String name)
A human-readable name for this library item.
|
ItemModel.Builder |
setSize(java.lang.Long size)
The library item size, in bytes.
|
ItemModel.Builder |
setSourceId(java.lang.String sourceId)
The identifier of the
ItemModel to which this
item is synchronized to if the item belongs to a subscribed library. |
ItemModel.Builder |
setType(java.lang.String type)
An optional type identifier which indicates the type adapter plugin to use.
|
ItemModel.Builder |
setVersion(java.lang.String version)
A version number that is updated on metadata changes.
|
public ItemModel.Builder()
ItemModel
.public ItemModel.Builder setId(java.lang.String id)
create
method. It will not be present
in the return value of the get
or list
methods. It is not used
for the update
method.id
- New value for the property.
When clients pass a value of this class as a parameter, the property must be an
identifier for the resource type: com.vmware.content.library.Item
. When
methods return a value of this class as a return value, the property will be an
identifier for the resource type: com.vmware.content.library.Item
.public ItemModel.Builder setLibraryId(java.lang.String libraryId)
LibraryModel
to which this item
belongs.
This property must be provided for the create
method. It will always be
present in the return value of the get
or list
methods. It is
not used for the update
method.libraryId
- New value for the property.
When clients pass a value of this class as a parameter, the property must be an
identifier for the resource type: com.vmware.content.Library
. When
methods return a value of this class as a return value, the property will be an
identifier for the resource type: com.vmware.content.Library
.public ItemModel.Builder setContentVersion(java.lang.String contentVersion)
create
method. It will always be
present in the return value of the get
or list
methods. It is
not used for the update
method.contentVersion
- New value for the property.public ItemModel.Builder setCreationTime(java.util.Calendar creationTime)
create
method. It will always be
present in the return value of the get
or list
methods. It is
not used for the update
method.creationTime
- New value for the property.public ItemModel.Builder setDescription(java.lang.String description)
create
method. Leaving it null
during creation will result in an empty string value. It will always be present
in the result of a get
or list
method. It is optional for the
update
method. Leaving it null
during update indicates that the
description remains unchanged.description
- New value for the property.public ItemModel.Builder setLastModifiedTime(java.util.Calendar lastModifiedTime)
This property is affected by changes to the properties or file content of this item. It is not modified by changes to the tags of the item, or by changes to the library which owns this item.
This property is not used for thecreate
method. It will always be
present in the return value of the get
or list
methods. It is
not used for the update
method.lastModifiedTime
- New value for the property.public ItemModel.Builder setLastSyncTime(java.util.Calendar lastSyncTime)
This
property is updated every time a synchronization is triggered on the library
item, including when a synchronization is triggered on the library to which this
item belongs. The value is null
for a library item that belongs to a
local library.
create
method. It is optional in the
return value of the get
or list
methods. It is not used for the
update
method.lastSyncTime
- New value for the property.public ItemModel.Builder setMetadataVersion(java.lang.String metadataVersion)
This value is incremented with each change to the metadata of this item. Changes to name, description, and so on will increment this value. The value is not incremented by changes to the content or tags of the item or the library which owns it.
This property is not used for thecreate
method. It will always be
present in the return value of the get
or list
methods. It is
not used for the update
method.metadataVersion
- New value for the property.public ItemModel.Builder setName(java.lang.String name)
The name may not be null
or an empty string. The name does not have to be unique, even within the
same library.
create
method. It will always be
present in the return value of the get
or list
methods. It is
optional for the update
method.name
- New value for the property.public ItemModel.Builder setCached(java.lang.Boolean cached)
create
method. It will always be
present in the return value of the get
or list
methods. It is
not used for the update
method.cached
- New value for the property.public ItemModel.Builder setSize(java.lang.Long size)
create
method. It is optional in the
return value of the get
or list
methods. It is not used for the
update
method.size
- New value for the property.public ItemModel.Builder setType(java.lang.String type)
This property may be set to a non-empty string value that corresponds to an identifier supported by a type adapter plugin present in the Content Library Service. A type adapter plugin, if present for the specified type, can provide additional information and services around the item content. A type adapter can guide the upload process by creating file entries that are in need of being uploaded to complete an item.
The types and plugins supported by the
Content Library Service can be queried using the Type
interface.
create
and update
methods.
During creation, if the type is left unspecified, or if the type is specified
but does not have a corresponding type support plugin, then the type of the
library item is considered to be generic and all data is treated as generic
files. During update, if the type is not specified, then it is not updated.type
- New value for the property.public ItemModel.Builder setVersion(java.lang.String version)
This value represents a number that is incremented every time library item properties, such as name or description, are changed. It is not incremented by changes to the file content of the library item, including adding or removing files. It is also not affected by tagging the library item.
This property is not used for thecreate
method. It will always be
present in the result of a get
or list
method. It is optional
for the update
method. Leaving it null
during update indicates
that you do not need to detect concurrent updates.version
- New value for the property.public ItemModel.Builder setSourceId(java.lang.String sourceId)
ItemModel
to which this
item is synchronized to if the item belongs to a subscribed library. The value
is null
for a library item that belongs to a local library.
This property is not used for the create
method. It is optional in the
return value of the get
or list
methods. It is not used for the
update
method.sourceId
- New value for the property.
When clients pass a value of this class as a parameter, the property must be an
identifier for the resource type: com.vmware.content.library.Item
. When
methods return a value of this class as a return value, the property will be an
identifier for the resource type: com.vmware.content.library.Item
.public ItemModel build()