Search operations - script to Java migration

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

Catalog

These script operations can be mapped to the following Catalog Java API methods.
Table 1. Script operations that map to the Catalog Java API methods
Script operation Java method
Catalog.getListOfCtgViewNames
CategoryTree. getListOfCtrViewNames
getViews()
Container.getCtgViewByName getView(String)
CtgView constructor createView(String)

Context

These script operations can be mapped to the following Context Java API methods.
Table 2. Script operations that map to the Context Java API methods
Script operation Java method
createSearchQuery() createSearchQuery()

Hierarchy

These script operations can be mapped to the following Hierarchy Java API methods.
Table 3. Script operations that map to the Hierarchy Java API methods
Script operation Java method
CategoryTree. getListOfCtrViewNames Hierarchy.getViews()
Container.getCtgViewByName Hierarchy.getView(String name)
CtgView constructor Hierarchy.createView(String viewName)

SearchQuery

These script operations can be mapped to the following SearchQuery Java API methods.
Table 4. Script operations that map to the SearchQuery Java API methods
Script operation Java method
SearchQuery::execute() execute()

SearchResultSet

These script operations can be mapped to the following SearchResultSet Java API methods.
Table 5. Script operations that map to the SearchResultSet Java API methods
Script operation Java method
SearchResultSet::size() size()
SearchResultSet::next() next()
SearchResultSet::next() getInt()
SearchResultSet::next() getDouble()
SearchResultSet::getLong() getLong()
SearchResultSet::getQuery() getSearchQuery()
SearchResultSet::getFloat() getFloat()
SearchResultSet::getString() getString()
SearchResultSet::getBoolean() getBoolean()
SearchResultSet::getDate() getDate()
SearchResultSet::getitem() getItem()
SearchResultSet::getCategory() getCategory()
SearchResultSet::getCatalog() getCatalog()
SearchResultSet::getHierarchy() getHierarchy()
SearchResultSet::getSpec() getSpec()

ScreenView

These script operations can be mapped to the following ScreenView Java API methods.
Table 6. Script operations that map to the ScreenView Java API methods
Script operation Java method
CtgView.getCtgViewAttrGroupsList getAttributeCollections
CtgView.getCtgViewAttribsList
getAttributes
getViewableAttributes
getEditableAttributes
CtgView.setCtgView
setEditableAttributeCollections
setViewableAttributeCollections
getView().save()
CtgView.getCtgViewPermission(String attributeCollectionName)
getEditableAttributeCollections().
contains(attrCol)
getViewableAttributeCollections().
contains(attrCol)
CtgView.getNewCtgTab
CtgView.addCtgTab
addFilter()
CtgView.insertCtgTabAt addFilter(int pos)
CtgView.removeCtgTabAt ScreenView.setFilters(Collection<ScreenViewFilter> filters)
CtgView.getCtgViewType getScreenType
CtgView.getCtgTabByName getFilter
CtgView.getCtgTabs getFilters

ScreenViewFilter

These script operations can be mapped to the following ScreenViewFilter Java API methods.
Table 7. Script operations that map to the ScreenViewFilter Java API methods
Script operation Java method
CtgTab.getCtgTabAttrGroupsList getAttributeCollections
CtgTab.getCtgTabName getName
CtgTab.setCtgTabRow[] setAttributeCollections
CtgTabRow.getTabRowPath AttributeDefinition.getPath

View

These script operations can be mapped to the following View Java API methods.
Table 8. Script operations that map to the View Java API methods
Script operation Java method
deleteCtgView delete
CtgView.saveCtgView save
CtgView.setCtgView getScreenView(ScreenType)