com.sas.dataselectors.filters
Class BusinessQueryToSimpleFilterListEditorModelAdapter

com.sas.dataselectors.filters.BusinessQueryToSimpleFilterListEditorModelAdapter
All Implemented Interfaces:
SimpleFilterDefinitionModelInterface, SimpleFilterListEditorModelInterface

public class BusinessQueryToSimpleFilterListEditorModelAdapter
implements SimpleFilterListEditorModelInterface


Field Summary
 
Fields inherited from class com.sas.dataselectors.filters.SimpleFilterListEditorModelBase
_adapter, _filterLogicList, _selectionIndex, _selectionModel
 
Constructor Summary
BusinessQueryToSimpleFilterListEditorModelAdapter()
          Constructs a new adapter using the default properties.
BusinessQueryToSimpleFilterListEditorModelAdapter(com.sas.storage.iquery.BusinessQueryAdapter businessQueryAdapter, FilterBaseModelData baseModel)
          Constructs a new adapter from the given native model.
BusinessQueryToSimpleFilterListEditorModelAdapter(com.sas.iquery.metadata.business.BusinessQuery businessQuery, FilterBaseModelData baseModel)
          Constructs a new adapter from the given native model.
BusinessQueryToSimpleFilterListEditorModelAdapter(com.sas.iquery.intelligentquery.BusinessQueryProviderInterface bqProvider, FilterBaseModelData baseModel)
          Constructs a new adapter from the given native model.
 
Method Summary
 boolean addSelection(FilterLogicTestNodeInterface value)
          Adds a new selection to the end of the filter logic list.
 boolean commitChanges()
          Commit any changes to the filter model and apply them to the native model.
 java.lang.Object getRootFilterObject()
          Returns the root filter object in the native model.
 int getSelectionCount()
          Get the number of selectable entries in the model.
 void removeSelection()
          Removes the current selection from the filter logic list.
 void setSelection(FilterLogicTestNodeInterface value)
          Sets the selection model for the adapter.
 
Methods inherited from class com.sas.dataselectors.filters.SimpleFilterListEditorModelBase
getApplicationData, getChangableSelectionModel, getDataSource, getFilterLogicList, getSelection, getSelectionCursor, setAdapter, setApplicationData, setSelectionCursor
 
Methods inherited from interface com.sas.dataselectors.filters.SimpleFilterListEditorModelInterface
getFilterLogicList, getSelectionCursor, setSelectionCursor
 
Methods inherited from interface com.sas.dataselectors.filters.SimpleFilterDefinitionModelInterface
getApplicationData, getDataSource, getSelection, setApplicationData
 

Constructor Detail

BusinessQueryToSimpleFilterListEditorModelAdapter

public BusinessQueryToSimpleFilterListEditorModelAdapter()
Constructs a new adapter using the default properties.


BusinessQueryToSimpleFilterListEditorModelAdapter

public BusinessQueryToSimpleFilterListEditorModelAdapter(com.sas.iquery.metadata.business.BusinessQuery businessQuery,
                                                         FilterBaseModelData baseModel)
Constructs a new adapter from the given native model.

Parameters:
businessQuery - the native model

BusinessQueryToSimpleFilterListEditorModelAdapter

public BusinessQueryToSimpleFilterListEditorModelAdapter(com.sas.storage.iquery.BusinessQueryAdapter businessQueryAdapter,
                                                         FilterBaseModelData baseModel)
Constructs a new adapter from the given native model.

Parameters:
businessQueryAdapter - the native model

BusinessQueryToSimpleFilterListEditorModelAdapter

public BusinessQueryToSimpleFilterListEditorModelAdapter(com.sas.iquery.intelligentquery.BusinessQueryProviderInterface bqProvider,
                                                         FilterBaseModelData baseModel)
Constructs a new adapter from the given native model.

Parameters:
bqProvider - the native model provider
Method Detail

setSelection

public void setSelection(FilterLogicTestNodeInterface value)
Sets the selection model for the adapter.

Specified by:
setSelection in interface SimpleFilterDefinitionModelInterface
Overrides:
setSelection in class SimpleFilterListEditorModelBase
Parameters:
value - the new selection
See Also:
SimpleFilterDefinitionModelInterface.setSelection(FilterLogicTestNodeInterface)

commitChanges

public boolean commitChanges()
Commit any changes to the filter model and apply them to the native model.

Specified by:
commitChanges in interface SimpleFilterDefinitionModelInterface
Overrides:
commitChanges in class SimpleFilterListEditorModelBase
Returns:
true if everything succeeded, false otherwise
See Also:
SimpleFilterDefinitionModelInterface.commitChanges()

getRootFilterObject

public java.lang.Object getRootFilterObject()
Returns the root filter object in the native model.

Specified by:
getRootFilterObject in interface SimpleFilterDefinitionModelInterface
Overrides:
getRootFilterObject in class SimpleFilterListEditorModelBase
Returns:
the root filter object

addSelection

public boolean addSelection(FilterLogicTestNodeInterface value)
Adds a new selection to the end of the filter logic list. The selection cursor position is unchanged after an add.

Specified by:
addSelection in interface SimpleFilterListEditorModelInterface
Overrides:
addSelection in class SimpleFilterListEditorModelBase
Parameters:
value - the filter logic test node values to make up the new object
Returns:
true if successful, false otherwise
See Also:
SimpleFilterListEditorModelInterface.addSelection(FilterLogicTestNodeInterface)

removeSelection

public void removeSelection()
Removes the current selection from the filter logic list. The selection cursor position is undefined after a removal.

Specified by:
removeSelection in interface SimpleFilterListEditorModelInterface
Overrides:
removeSelection in class SimpleFilterListEditorModelBase
See Also:
SimpleFilterListEditorModelInterface.removeSelection()

getSelectionCount

public int getSelectionCount()
Get the number of selectable entries in the model.

Specified by:
getSelectionCount in interface SimpleFilterListEditorModelInterface
Overrides:
getSelectionCount in class SimpleFilterListEditorModelBase
Returns:
the number of selectable entries
See Also:
SimpleFilterListEditorModelInterface.getSelectionCursor()



Copyright © 2009 SAS Institute Inc. All Rights Reserved.