io.clarify.api
Class BundleMetadata
java.lang.Object
io.clarify.api.ClarifyModel
io.clarify.api.BundleMetadata
public class BundleMetadata
- extends ClarifyModel
Provides details on the stored Metadata for a specific media Bundle. Metadata may also contain user data within
the data field as any JSON payload
|
Method Summary |
String |
getBundleId()
|
boolean |
resetData()
Delete the metadata of a bundle and set data to {} (empty object.)
This is functionally equivalent to an update metadata request with data set to {}. |
BundleMetadata |
updateData(String json)
Updates the user-defined data property of the Bundle's Metadata with the supplied JSON string,
then return a refreshed copy (resulting in 2 API calls) |
client
protected ClarifyClient client
BundleMetadata
public BundleMetadata(ClarifyClient client,
ClarifyResponse response)
resetData
public boolean resetData()
throws IOException
- Delete the metadata of a bundle and set data to {} (empty object.)
This is functionally equivalent to an update metadata request with data set to {}.
- Returns:
- true if the operation succeeded
- Throws:
IOException - if a failure occurred during the API,
typically a 4xx HTTP error code + JSON payload with the error message and details
updateData
public BundleMetadata updateData(String json)
throws IOException
- Updates the user-defined data property of the Bundle's Metadata with the supplied JSON string,
then return a refreshed copy (resulting in 2 API calls)
- Parameters:
json - a String containing valid JSON, or null. If null is passed, then the data is reset to a JSON equiv of {}
- Returns:
- a refreshed Metadata instance for the media bundle
- Throws:
IOException - if a failure occurred during the API,
typically a 4xx HTTP error code + JSON payload with the error message and details
getBundleId
public String getBundleId()
Copyright © 2015 Clarify Inc. All Rights Reserved.