IlpAbstractTreeAdapter adapter = tree.getAdapter();
// Setting the filter
IlpFilter myFilter = new MyFilter();
// (it is the same as tree.setFilter(myFilter)
adapter.setFilter(myFilter);
// Origin
List myOrigins = new ArrayList();
myOrigins.add(objectID_1);
myOrigins.add(objectID_2);
.
.
.
myOrigins.add(objectID_n);
// in this case we want to display the
// origins
boolean showOrigin = true;
adapter.setOrigins(myOrigins, showOrigin);
// Expansion Strategy Factory
// Usually the expansion strategy factory relies
// on the adapter to access the data source and to
// load/release objects
IlpExpansionStrategyFactory myExpFactory = new
MyExpansionStrategyFactory(adapter);
adapter.setExpansionStrategyFactory(myExpFactory);
// Tree Node Factory
IlpTreeNodeFactory myNodeFactory = new MyTreeNodeFactory();
adapter.setNodeFactory(myNodeFactory);
// Setting the object attribute value changed event filter IlpFilter
myEventFilter = new MyEventFilter();
adapter.setObjectAttributeChangedFilter(myEventFilter);