Selections operations - script to Java migration

The migration tables list the script operations that map to Selections Java™ API methods.

DynamicItemSelection

These script operations can be mapped to the following DynamicItemSelection Java API methods.
Table 1. Script operations that map to the DynamicItemSelection Java API methods
Script operation Java method
ItemSet Selection::getItemSetForSelection() getItems()
Catalog Selection::getSelectionCatalog() getCatalog()
void
DynamicSelection::setDynamic
SelectionQueryString(String
queryString)
setQuery(String query)

DynamicSelection

These script operations can be mapped to the following DynamicSelection Java API methods.
Table 2. Script operations that map to the DynamicSelection Java API methods
Script operation Java method
String
DynamicSelection::getDynamic
SelectionQueryString()
getQuery()

Selection

These script operations can be mapped to the following Selection Java API methods.
Table 3. Script operations that map to the Selection Java API methods
Script operation Java method
String Selection::getSelectionName() getName()
String Selection::getSelectionAccess
ControlGroupName()
getAccessControlGroup ()
void Selection::setSelectionName(String name) setName(String name)
void
Selection::setSelectionAccessControl
GroupName(String acgName)
setAccessControlGroup (AccessControlGroup acg)
void Selection::saveSelection() save()
boolean Selection::deleteSelection() delete()
Integer Selection::getSelectionItemCount() getCount()

SelectionManager

These script operations can be mapped to the following SelectionManager Java API methods.
Table 4. Script operations that map to the SelectionManager Java API methods
Script operation Java method
new BasicSelection(Catalog catalog, String name) createStaticItemSelection(Catalog catalog, Hierarchy hierarchy, String selectionName)
new DynamicSelection(String selectionName, String queryString) createDynamicItemSelection(String selectionName, String query)
String[] getSelectionNamesList(Catalog catalog) SelectionManager.getSelections(Catalog catalog)
Selection getSelectionByName(String sName) getSelection(String selectionName)

StaticItemSelection

These script operations can be mapped to the following StaticItemSelection Java API methods.
Table 5. Script operations that map to the StaticItemSelection Java API methods
Script operation Java method
void Selection::addEntryToSelection(Entry entry) addItem (Item item)
Integer Selection::getSelectionHierarchyNodeCount() getCategoryCount()
HierarchyNodeSet Selection::getHierarchyNodeSetForSelection() getCategories()
Hierarchy Selection::getSelectionHierarchy() getHierarchy()
ItemSet Selection::getItemSetForSelection() getItems()
Catalog Selection::getSelectionCatalog() getCatalog()