public class MetadataTemplate extends BoxJSONObject
Modifier and Type | Class and Description |
---|---|
class |
MetadataTemplate.Field
Class contains information about the metadata template field.
|
Constructor and Description |
---|
MetadataTemplate()
Constructs an empty metadata template.
|
MetadataTemplate(String json)
Constructs a metadata template from a JSON string.
|
Modifier and Type | Method and Description |
---|---|
String |
getDisplayName()
Gets the displayed metadata template name.
|
static Iterable<MetadataTemplate> |
getEnterpriseMetadataTemplates(BoxAPIConnection api,
String... fields)
Returns all metadata templates within a user's enterprise.
|
static Iterable<MetadataTemplate> |
getEnterpriseMetadataTemplates(String scope,
BoxAPIConnection api,
String... fields)
Returns all metadata templates within a user's scope.
|
static Iterable<MetadataTemplate> |
getEnterpriseMetadataTemplates(String scope,
int limit,
BoxAPIConnection api,
String... fields)
Returns all metadata templates within a user's scope.
|
List<MetadataTemplate.Field> |
getFields()
Gets the iterable with all fields the metadata template contains.
|
Boolean |
getIsHidden()
Gets is the metadata template hidden.
|
static MetadataTemplate |
getMetadataTemplate(BoxAPIConnection api)
Gets the metadata template of properties.
|
static MetadataTemplate |
getMetadataTemplate(BoxAPIConnection api,
String templateName)
Gets the metadata template of specified template type.
|
static MetadataTemplate |
getMetadataTemplate(BoxAPIConnection api,
String templateName,
String scope,
String... fields)
Gets the metadata template of specified template type.
|
String |
getScope()
Gets the metadata template scope.
|
String |
getTemplateKey()
Gets the unique template key to identify the metadata template.
|
clearPendingChanges, getPendingChanges
public MetadataTemplate()
public MetadataTemplate(String json)
json
- the json encoded metadate template.public String getTemplateKey()
public String getScope()
public String getDisplayName()
public Boolean getIsHidden()
public List<MetadataTemplate.Field> getFields()
public static MetadataTemplate getMetadataTemplate(BoxAPIConnection api)
api
- the API connection to be used.public static MetadataTemplate getMetadataTemplate(BoxAPIConnection api, String templateName)
api
- the API connection to be used.templateName
- the metadata template type name.public static MetadataTemplate getMetadataTemplate(BoxAPIConnection api, String templateName, String scope, String... fields)
api
- the API connection to be used.templateName
- the metadata template type name.scope
- the metadata template scope (global or enterprise).fields
- the fields to retrieve.public static Iterable<MetadataTemplate> getEnterpriseMetadataTemplates(BoxAPIConnection api, String... fields)
api
- the API connection to be used.fields
- the fields to retrieve.public static Iterable<MetadataTemplate> getEnterpriseMetadataTemplates(String scope, BoxAPIConnection api, String... fields)
scope
- the scope of the metadata templates.api
- the API connection to be used.fields
- the fields to retrieve.public static Iterable<MetadataTemplate> getEnterpriseMetadataTemplates(String scope, int limit, BoxAPIConnection api, String... fields)
scope
- the scope of the metadata templates.limit
- maximum number of entries per response.api
- the API connection to be used.fields
- the fields to retrieve.