public interface ImageResource extends AuthenticatedResource
Modifier and Type | Method and Description |
---|---|
ImageLoadResponse |
create(ImageCreateRequest request)
Create a new image
|
GenericResponse |
delete(Integer id,
Integer nodeId)
Delete the image denoted by id
|
GenericResponse |
deleteFromWastebin(IdSetRequest request,
long waitMs)
Remove the given images from the wastebin
|
GenericResponse |
deleteFromWastebin(String id,
long waitMs)
Remove the image denoted by the given id from the wastebin.
|
MultiDisinheritResponse |
disinherit(List<String> ids,
Integer nodeId)
Get the multichannelling exclusion and disinherit status for a list of images
|
GenericResponse |
disinherit(List<String> ids,
Integer nodeId,
long waitMs,
DisinheritRequest request)
Set the multichannelling exclusion and disinherit status for a list of images
|
DisinheritResponse |
disinherit(String id,
Integer nodeId)
Get the multichannelling exclusion and disinherit status of the file
|
GenericResponse |
disinherit(String id,
Integer nodeId,
long waitMs,
DisinheritRequest request)
Set the multichannelling exclusion and disinherit status
|
FileUsageListResponse |
getFileUsageInfo(Integer skipCount,
Integer maxItems,
String sortBy,
String sortOrder,
List<Integer> imageId,
Integer nodeId,
boolean returnFiles)
Get the files using one of the given images
|
FolderUsageListResponse |
getFolderUsageInfo(Integer skipCount,
Integer maxItems,
String sortBy,
String sortOrder,
List<Integer> imageId,
Integer nodeId,
boolean returnFolders)
Get the folders using one of the given images
|
FileUsageListResponse |
getImageUsageInfo(Integer skipCount,
Integer maxItems,
String sortBy,
String sortOrder,
List<Integer> imageId,
Integer nodeId,
boolean returnImages)
Get the images using one of the given images
|
LocalizationInfo |
getLocalizationInfo(List<Integer> ids,
Integer nodeId)
Get localization info for a list of images for a given channel and all master channels
|
LocalizationInfo |
getLocalizationInfo(String id,
Integer nodeId)
Get localization info for an image for a given channel and all master channels
|
PageUsageListResponse |
getPageUsageInfo(Integer skipCount,
Integer maxItems,
String sortBy,
String sortOrder,
List<Integer> imageId,
Integer nodeId,
boolean returnPages,
boolean template,
boolean folder,
boolean languageVariants)
Get the pages using one of the given images
|
PrivilegesResponse |
getPrivileges(Integer id)
Get the privileges of the current user on the given image
|
TemplateUsageListResponse |
getTemplateUsageInfo(Integer skipCount,
Integer maxItems,
String sortBy,
String sortOrder,
List<Integer> imageId,
Integer nodeId,
boolean returnTemplates)
Get the templates using one of the given images
|
ImageLoadResponse |
load(String id,
boolean update,
Integer nodeId)
Load the image with given id
|
javax.ws.rs.core.Response |
loadContent(Integer id)
Get the content of the image with given id
|
GenericResponse |
localize(Integer id,
LocalizeRequest request)
Localize the given image
|
GenericResponse |
move(MultiObjectMoveRequest request)
Move multiple files to another folder
|
GenericResponse |
move(String id,
ObjectMoveRequest request)
Mpve the given file to another folder
|
GenericResponse |
pushToMaster(Integer id,
PushToMasterRequest request)
Push an image from a channel into a master
|
GenericResponse |
pushToMaster(MultiPushToMasterRequest request)
Push a list of images from a channel into a master
|
FileUploadResponse |
resize(ImageResizeRequest imageResizeRequest)
This method will once invoked resize the image and update its binary data
and properties.
|
GenericResponse |
restoreFromWastebin(IdSetRequest request,
long waitMs)
Restore the given images from the wastebin
|
GenericResponse |
restoreFromWastebin(String id,
long waitMs)
Restore the given image from the wastebin
|
GenericResponse |
save(Integer id,
ImageSaveRequest request)
Save the given image
|
GenericResponse |
saveContent(InputStream fileContent)
Save the posted content into the given image
|
GenericResponse |
unlocalize(Integer id,
UnlocalizeRequest request)
Unlocalize the given image
|
GenericResponse |
unlocalize(MultiUnlocalizeRequest request)
Unlocalize images in a channel
|
setSessionId
ImageLoadResponse load(String id, boolean update, Integer nodeId)
id
- image id. This can either be a local or globalidupdate
- true when the image is fetched for updating. Currently, images
cannot be locked in the backend, but it is still recommended
to set this parameter to true when the image shall be modified.nodeId
- id of the node (channel) for which the image shall be
loaded (when multichannelling is used).FileUploadResponse resize(ImageResizeRequest imageResizeRequest)
javax.ws.rs.core.Response loadContent(Integer id)
id
- image id to getImageLoadResponse create(ImageCreateRequest request)
request
- request with data for the image to be createdGenericResponse move(String id, ObjectMoveRequest request)
id
- file idrequest
- requestGenericResponse move(MultiObjectMoveRequest request)
request
- requestGenericResponse save(Integer id, ImageSaveRequest request)
request
- request with the image to be savedGenericResponse saveContent(InputStream fileContent)
fileContent
- image contentGenericResponse delete(Integer id, Integer nodeId)
id
- id of the image to deleteGenericResponse deleteFromWastebin(String id, long waitMs)
id
- id of the image to remove from the wastebin. This can either be
a local or global idwaitMs
- time in ms for the request to be done in foregroundGenericResponse deleteFromWastebin(IdSetRequest request, long waitMs)
request
- request containing the image IDswaitMs
- time in ms for the request to be done in foregroundGenericResponse restoreFromWastebin(String id, long waitMs)
id
- id of the image to restore from the wastebin. This can either
be a local or global idwaitMs
- time in ms for the request to be done in foregroundGenericResponse restoreFromWastebin(IdSetRequest request, long waitMs)
request
- request containing the image IDswaitMs
- time in ms for the request to be done in foregroundPrivilegesResponse getPrivileges(Integer id)
id
- id of the imageFolderUsageListResponse getFolderUsageInfo(Integer skipCount, Integer maxItems, String sortBy, String sortOrder, List<Integer> imageId, Integer nodeId, boolean returnFolders)
skipCount
- number of items to be skipped, set to 0 for skipping no itemsmaxItems
- maximum number of items to be returned, set to -1 for
returning all itemssortby
- (optional) attribute to sort by. defaults to namesortorder
- (optional) result sort order - may be "asc" for ascending or
"desc" for descending other strings will be ignored. defaults
to "asc".imageId
- list of image ids, for which the usage shall be fetchednodeId
- id of the nodereturnFolders
- true (default) if the folders shall be returned, false for only returning the countsPageUsageListResponse getPageUsageInfo(Integer skipCount, Integer maxItems, String sortBy, String sortOrder, List<Integer> imageId, Integer nodeId, boolean returnPages, boolean template, boolean folder, boolean languageVariants)
skipCount
- number of items to be skipped, set to 0 for skipping no itemsmaxItems
- maximum number of items to be returned, set to -1 for
returning all itemssortby
- (optional) attribute to sort by. defaults to namesortorder
- (optional) result sort order - may be "asc" for ascending or
"desc" for descending other strings will be ignored. defaults
to "asc".imageId
- list of image ids, for which the usage shall be fetchednodeId
- id of the nodereturnPages
- true (default) if the pages shall be returned, false for only returning the countstemplate
- true for adding template info to the pages, default is falsefolder
- true for adding folder info to the pages, default is falselanguageVariants
- true for adding the language variants to the pages, default is falseTemplateUsageListResponse getTemplateUsageInfo(Integer skipCount, Integer maxItems, String sortBy, String sortOrder, List<Integer> imageId, Integer nodeId, boolean returnTemplates)
skipCount
- number of items to be skipped, set to 0 for skipping no itemsmaxItems
- maximum number of items to be returned, set to -1 for
returning all itemssortby
- (optional) attribute to sort by. defaults to namesortorder
- (optional) result sort order - may be "asc" for ascending or
"desc" for descending other strings will be ignored. defaults
to "asc".imageId
- list of image ids, for which the usage shall be fetchednodeId
- id of the nodereturnTemplates
- true (default) if the templates shall be returned, false for only returning the countsFileUsageListResponse getImageUsageInfo(Integer skipCount, Integer maxItems, String sortBy, String sortOrder, List<Integer> imageId, Integer nodeId, boolean returnImages)
skipCount
- number of items to be skipped, set to 0 for skipping no itemsmaxItems
- maximum number of items to be returned, set to -1 for
returning all itemssortby
- (optional) attribute to sort by. defaults to namesortorder
- (optional) result sort order - may be "asc" for ascending or
"desc" for descending other strings will be ignored. defaults
to "asc".imageId
- list of image ids, for which the usage shall be fetchednodeId
- id of the nodereturnImages
- true (default) if the images shall be returned, false for only returning the countsFileUsageListResponse getFileUsageInfo(Integer skipCount, Integer maxItems, String sortBy, String sortOrder, List<Integer> imageId, Integer nodeId, boolean returnFiles)
skipCount
- number of items to be skipped, set to 0 for skipping no itemsmaxItems
- maximum number of items to be returned, set to -1 for
returning all itemssortby
- (optional) attribute to sort by. defaults to namesortorder
- (optional) result sort order - may be "asc" for ascending or
"desc" for descending other strings will be ignored. defaults
to "asc".imageId
- list of image ids, for which the usage shall be fetchednodeId
- id of the nodereturnFiles
- true (default) if the files shall be returned, false for only returning the countsGenericResponse pushToMaster(Integer id, PushToMasterRequest request)
id
- id of the imagerequest
- requestGenericResponse pushToMaster(MultiPushToMasterRequest request)
request
- requestGenericResponse unlocalize(Integer id, UnlocalizeRequest request)
id
- id of the image to unlocalizerequest
- requestGenericResponse unlocalize(MultiUnlocalizeRequest request)
request
- requestGenericResponse localize(Integer id, LocalizeRequest request)
id
- id of the image to localizerequest
- requestLocalizationInfo getLocalizationInfo(List<Integer> ids, Integer nodeId)
ids
- list of image idsnodeId
- id of the node to start withLocalizationInfo getLocalizationInfo(String id, Integer nodeId)
id
- id of the image. The id can either be the local or global idnodeId
- id of the node to start withDisinheritResponse disinherit(String id, Integer nodeId) throws Exception
id
- file IDnodeId
- node IDException
GenericResponse disinherit(String id, Integer nodeId, long waitMs, DisinheritRequest request) throws Exception
id
- file IDnodeId
- node IDwaitMs
- wait timeout in millisecondsrequest
- request objectException
MultiDisinheritResponse disinherit(List<String> ids, Integer nodeId) throws Exception
ids
- list of image IDsnodeId
- node IDException
GenericResponse disinherit(List<String> ids, Integer nodeId, long waitMs, DisinheritRequest request) throws Exception
ids
- list of image IDsnodeId
- node IDwaitMs
- wait timeout in millisecondsrequest
- request objectException
Copyright © 2015 Gentics Software GmbH. All rights reserved.