public class MultiRecordItemCollection extends MultiItemCollection
RecordItemCollection
objects for different catalogs. You can create a new instance using Server.newMultiRecordItemCollection()
.Modifier and Type | Method and Description |
---|---|
MultiRecordItemCollection |
clone(boolean createEmptyClone)
Create a clone of this collection.
|
MultiRecordItemCollection |
clone(boolean createEmptyClone,
boolean createNewCollection)
Create a clone of this collection.
|
void |
find(java.util.Map<java.lang.Integer,java.util.Set<java.lang.Integer>> categoryIDs,
java.util.EnumSet<FindFlag> flags,
CombineMode combine)
Find record items using the categories assigned to them.
|
void |
find(java.util.Map<java.lang.Integer,java.util.Set<java.lang.Integer>> categoryIDs,
java.util.EnumSet<FindFlag> flags,
CombineMode combine,
boolean logSearchStatistic)
Find record items using the categories assigned to them.
|
java.lang.String |
getMasterAssetsOnlyQuery()
Return a query string that find only master assets.
|
RecordItem |
getRecordItemByID(int catalogID,
int recordID)
Return a record item specified by catalog ID and item ID.
|
RecordItem |
getRecordItemByID(ItemIdentifier itemIdentifier)
Return a record item specified by identifier.
|
RecordItemCollection |
getRecordItemCollection(int catalogID)
Return the contained RecordItemCollection for the given catalog ID.
|
JPack |
save(java.lang.String collectionSetName,
boolean sharedSet,
CollectionType type)
Save the contents of this collection at the Cumulus server.
|
JPack |
save(java.lang.String collectionSetName,
CollectionType type,
java.util.Date expirationDate)
Save the contents of this collection as a shared collection at the Cumulus server.
|
addCollectionListener, addFilter, addFilter, addFilter, addFilter, addFilter, addGlobalCollectionListener, addItem, addItem, addItemCollection, addItems, close, doAssetAction, doAssetAction, doAssetAction, equals, find, find, find, find, find, find, find, find, findAll, findAll, getCatalogIDs, getCumulusSession, getDailyStatistics, getDailyStatistics, getItemByID, getItemByID, getItemCollection, getItemCount, getItemFieldStatistics, getItemFieldsWithStatistics, getItemFieldsWithStatistics, getItemFieldsWithStatistics, getItemFieldValues, getItemIDs, getItemPosition, getItemPosition, getItemTotalCount, getMultiLayout, getMultiSorting, getServer, getSortDirection, getSorting, getTableName, hashCode, hasItem, iterator, matchIDs, moveItem, quickSearch, removeAllItems, removeCollectionListener, removeFilter, removeGlobalCollectionListener, removeItem, removeItem, removeItemCollection, removeItems, setFreesorted, setMultiSorting, setSortDirection, setSorting, updateWantedFields, updateWantedFields
public MultiRecordItemCollection clone(boolean createEmptyClone)
clone
in class MultiItemCollection
createEmptyClone
- Pass true
if you want the new collection to be empty. Pass false
if it should contain the same items as
this collection.public MultiRecordItemCollection clone(boolean createEmptyClone, boolean createNewCollection)
clone
in class MultiItemCollection
createEmptyClone
- Pass true
if you want the new collection to be empty. Pass false
if it should contain the same items
as this collection.createNewCollection
- Pass true
if you want the new collection has no specific filters and sorting settings. Pass false
if
you want the new collection to have the same filters and sorting settings as this collection.public RecordItem getRecordItemByID(ItemIdentifier itemIdentifier) throws ItemNotFoundException, CumulusException
itemIdentifier
- The identifier of the record item to be returned.ItemNotFoundException
- if the collection does not contain the given item.CumulusException
- on other errors.public RecordItem getRecordItemByID(int catalogID, int recordID) throws ItemNotFoundException, CumulusException
RecordItem
instance instead of an Item
instance. This method returns the same result as MultiItemCollection.getItemByID(int, int)
but is
declared to return a RecordItem.catalogID
- The ID of the item's catalog to be returned.recordID
- The ID of the record item to be returned.ItemNotFoundException
- if the collection does not contain the given item.CumulusException
- on other errors.public RecordItemCollection getRecordItemCollection(int catalogID) throws InvalidArgumentException, CumulusException
RecordItemCollection
instance instead of an ItemCollection
instance. This method returns the same result as MultiItemCollection.getItemCollection(int)
but is declared to return a RecordItemCollection.catalogID
- The catalog ID of the collection to be returned.InvalidArgumentException
- if the catalog ID is not validCumulusException
- on other errorsMultiItemCollection.addItemCollection(ItemCollection)
,
MultiItemCollection.getItemCollection(int)
public void find(java.util.Map<java.lang.Integer,java.util.Set<java.lang.Integer>> categoryIDs, java.util.EnumSet<FindFlag> flags, CombineMode combine) throws CumulusException
categoryIDs
- A map using the catalog ID as key and a set of category IDs per catalog as value. These are the categories to match.flags
- options that determine how to use the categories for searching. Either specify null
or FindFlag.SEARCH_CATEGORIES_USE_USER_SETTINGS
to use te current user's setting for these options or
specify individual flags such as FindFlag.SEARCH_CATEGORIES_ABOVE
, FindFlag.SEARCH_CATEGORIES_BELOW
, FindFlag.SEARCH_CATEGORIES_EXACT
,
FindFlag.SEARCH_CATEGORIES_MATCH_ONE
, or FindFlag.SEARCH_CATEGORIES_RESOLVE_RELATED
.combine
- specifies how to combine the result of this search with the existing contents of the collection.: CombineMode.FIND_NEW
: the search replaces the current contents of the collection.CombineMode.FIND_NARROW
: the search result will only leave the items in the collection that match the
query.CombineMode.FIND_BROADEN
: the search result will be added to the current
collection contents.CumulusException
- on errors (e.g. wrong catalog ID or category ID)public void find(java.util.Map<java.lang.Integer,java.util.Set<java.lang.Integer>> categoryIDs, java.util.EnumSet<FindFlag> flags, CombineMode combine, boolean logSearchStatistic) throws CumulusException
categoryIDs
- A map using the catalog ID as key and a set of category IDs per catalog as value. These are the categories to match.flags
- options that determine how to use the categories for searching. Either specify null
or FindFlag.SEARCH_CATEGORIES_USE_USER_SETTINGS
to use te current user's setting for these options or
specify individual flags such as FindFlag.SEARCH_CATEGORIES_ABOVE
, FindFlag.SEARCH_CATEGORIES_BELOW
, FindFlag.SEARCH_CATEGORIES_EXACT
,
FindFlag.SEARCH_CATEGORIES_MATCH_ONE
, or FindFlag.SEARCH_CATEGORIES_RESOLVE_RELATED
.combine
- specifies how to combine the result of this search with the existing contents of the collection.: CombineMode.FIND_NEW
: the search replaces the current contents of the collection.CombineMode.FIND_NARROW
: the search result will only leave the items in the collection that match the
query.CombineMode.FIND_BROADEN
: the search result will be added to the current
collection contents.logSearchStatistic
- specifies whether the query result has to be logged in the search statisticCumulusException
- on errors (e.g. wrong catalog ID or category ID)public JPack save(java.lang.String collectionSetName, boolean sharedSet, CollectionType type) throws PermissionDeniedException, CumulusException
collectionSetName
- The name of the collection at the server.sharedSet
- Pass true
to make the collection shared among users, false
if you want to allow access only to the
current user.type
- The type of collection to create. Typically you create a CollectionType.NORMAL_COLLECTION
.
The other types are used internally and serve a special purpose.PermissionDeniedException
- if the current user does not have the necessary permission for this operation.CumulusException
- on other errors.public JPack save(java.lang.String collectionSetName, CollectionType type, java.util.Date expirationDate) throws PermissionDeniedException, CumulusException
collectionSetName
- The name of the collection at the server.type
- The type of collection to create. Typically you create a CollectionType.NORMAL_COLLECTION
.
The other types are used internally and serve a special purpose.expirationDate
- The date when the created collection should be deleted automatically at the cumulus server.PermissionDeniedException
- if the current user does not have the necessary permission for this operation.CumulusException
- on other errors.public java.lang.String getMasterAssetsOnlyQuery()
www.canto.com
Canto, the Canto logo, the Cumulus logo, and Cumulus are registered trademarks of Canto GmbH, registered in the U.S. and other countries.