All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sas.dataselectors.filters
Class BusinessModelFilterItemToAdvancedLogicListAdapter

    com.sas.dataselectors.filters.BusinessModelFilterItemToAdvancedLogicListAdapter

All Implemented Interfaces:
  FilterLogicListInterface, SimpleLogicListAdapterInterface, SimpleLogicListInterface, java.lang.Iterable, java.util.Collection, java.util.List

    public class BusinessModelFilterItemToAdvancedLogicListAdapter

This class extends the simple logic list base to add BusinessModel specific behavior.

Field Summary
`protected FilterBaseModelData` | `_baseModel` A wrapper for the native model.
`protected SimpleFilterLogicTreeInterface` | `_filterLogicTree` The filter logic tree.
`protected FilterObjectFactoryInterface` | `_filterObjectFactory` The filter object factory used by the adapter when converting between the native model and the filter model.

Fields inherited from class com.sas.dataselectors.filters.AbstractSimpleLogicListAdapterBase
`_filterItemList, _filterItemSimpleList`

Constructor Summary
`BusinessModelFilterItemToAdvancedLogicListAdapter(FilterBaseModelData baseModel, com.sas.iquery.metadata.business.FilterItem initialFilter, int environment)` Constructs a new adapter from the specified model and initial filter item.
`BusinessModelFilterItemToAdvancedLogicListAdapter(FilterBaseModelData baseModel, int environment)` Constructs a new adapter from the specified model and default object factory.
`BusinessModelFilterItemToAdvancedLogicListAdapter(FilterObjectFactoryInterface filterObjectFactory, FilterBaseModelData baseModel, int environment)` Constructs a new adapter from the specified model and object factory.

Method Summary
`boolean` | `commitChanges()` Commit changed data to the native model.
`com.sas.iquery.metadata.business.BusinessModel` | `getBusinessModel()` Returns the native filter model for the adapter.
`SimpleFilterLogicTreeInterface` | `getFilterLogicTree()` Returns the filter logic tree.
`FilterObjectFactoryInterface` | `getFilterObjectFactory()` Returns the filter object factory.
`void` | `setBusinessModel(com.sas.iquery.metadata.business.BusinessModel businessModel)` Sets the native filter model for the adapter.
`void` | `setEnvironment(int environment)` Sets the operating environment to the specified value.
`void` | `setFilterObjectFactory(FilterObjectFactoryInterface filterObjectFactory)` Sets the filter object factory.

Methods inherited from class com.sas.dataselectors.filters.AbstractSimpleLogicListAdapterBase
`add, add, addAll, addAll, clear, contains, containsAll, equals, get, getFilterItemList, getFilterList, getFilterLogicList, getRootFilterObject, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, setFilterItemList, setFilterList, setFilterList, size, subList, toArray, toArray`

Methods inherited from class com.sas.dataselectors.filters.DefaultFilterLogicList
`getFilterListDescription, getFilterListLabel, setFilterListDescription, setFilterListLabel, toString`

Field Detail

### _baseModel

    protected FilterBaseModelData _baseModel

  A wrapper for the native model.

### _filterObjectFactory

    protected FilterObjectFactoryInterface _filterObjectFactory

  The filter object factory used by the adapter when converting between the native model and the filter model.

### _filterLogicTree

    protected SimpleFilterLogicTreeInterface _filterLogicTree

  The filter logic tree. The filter logic tree contains the elements and structure that make up the filter.

Constructor Detail

### BusinessModelFilterItemToAdvancedLogicListAdapter

    public BusinessModelFilterItemToAdvancedLogicListAdapter(FilterBaseModelData baseModel,
                                                             com.sas.iquery.metadata.business.FilterItem initialFilter,
                                                             int environment)

  Constructs a new adapter from the specified model and initial filter item. The default object factory will be used. The initial filter (if not null) will provide the initial structure and composition of the filter logic tree.

  Parameters:
    `businessModel` - the model for the adapter
    `initialFilter` - the initial filter from the native model to work with
    `environment` - the operating environment (e.g. Swing,JSP)

### BusinessModelFilterItemToAdvancedLogicListAdapter

    public BusinessModelFilterItemToAdvancedLogicListAdapter(FilterBaseModelData baseModel,
                                                             int environment)

  Constructs a new adapter from the specified model and default object factory.

  Parameters:
    `businessModel` - the model for the adapter
    `environment` - the operating environment (e.g. Swing,JSP)

### BusinessModelFilterItemToAdvancedLogicListAdapter

    public BusinessModelFilterItemToAdvancedLogicListAdapter(FilterObjectFactoryInterface filterObjectFactory,
                                                             FilterBaseModelData baseModel,
                                                             int environment)

  Constructs a new adapter from the specified model and object factory. The filter object factory is used by the adapter when converting between the native model and the filter model.

  Parameters:
    `filterObjectFactory` - the factory used during conversions
    `businessModel` - the model for the adapter
    `environment` - the operating environment (e.g. Swing,JSP)

Method Detail

### getFilterLogicTree

    public SimpleFilterLogicTreeInterface getFilterLogicTree()

  Returns the filter logic tree. The filter logic tree contains the elements and structure that make up the filter.

  Returns:
    the filter logic tree

### commitChanges

    public boolean commitChanges()

  Commit changed data to the native model.

  Specified by:
    `commitChanges` in interface `SimpleLogicListInterface`
  Specified by:
    `commitChanges` in class `AbstractSimpleLogicListAdapterBase`
  Returns:
    true if the native model was successfully updated, false otherwise

### getBusinessModel

    public com.sas.iquery.metadata.business.BusinessModel getBusinessModel()

  Returns the native filter model for the adapter.

  Returns:
    the model for the adapter

### setBusinessModel

    public void setBusinessModel(com.sas.iquery.metadata.business.BusinessModel businessModel)

  Sets the native filter model for the adapter.

  Parameters:
    `businessModel` - the new model for the adapter

### getFilterObjectFactory

    public FilterObjectFactoryInterface getFilterObjectFactory()

  Returns the filter object factory. The factory is used when converting between the native and filter models.

  Returns:
    the filter object factory used by the adapter

### setFilterObjectFactory

    public void setFilterObjectFactory(FilterObjectFactoryInterface filterObjectFactory)

  Sets the filter object factory. The factory is used when converting between the native and filter models.

  Parameters:
    `filterObjectFactory` - the new filter object factory to use

### setEnvironment

    public void setEnvironment(int environment)

  Sets the operating environment to the specified value.

  Parameters:
    `environment` - The environment to set. Valid values are defined in com.sas.util.OperatingEnvironmentInterface.

All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SAS Institute Inc. All Rights Reserved.