The adapter

The table adapter converts business objects retrieved from the associated data source to table rows. The table adapter is defined by the interface IlpListAdapter. This adapter does not create representation objects in a table model but in a list model. This list model and the representation objects it contains are transformed into a table model at the level of the table component.
The default table adapter implementation provides the following services:
The following figure shows the table adapter classes:
tgo_table_adapter.png
Table adapter classes
A given IlpListAdapter instance can only represent IlpClass objects of the same type. So that only objects of a specific class or of one of its subclasses be represented, you should set this class with the setAcceptedClass method.
The following code plugs an IltDefaultDataSource to an IlpTableModel through an IlpTableListAdapter.

How to create a table adapter by instantiating a table component

IlpTable ilpTable = new IlpTable();
IltDefaultDataSource dataSource = new IltDefaultDataSource();
ilpTable.setDataSource(dataSource, acceptedClass);

How to retrieve a table adapter

IlpTableListAdapter adapter = ilpTable.getAdapter();

How to set your own adapter to the table component

IlpTable ilpTable= new IlpTable();
IlpTableListAdapter adapter = new IlpTableListAdapter();
ilpTable.setAdapter(adapter);
ilpTable.setAcceptedClass(acceptedClass);
IltDefaultDataSource dataSource = new IltDefaultDataSource();
ilpTable.setDataSource(dataSource);
List adapters use by default an IlpTableRowFactory that creates representation objects of type IlpDefaultTableRow.
You can create a table adapter implicitly by instantiating the IlpTable component, as shown in the following example.

Representation object factory

The table adapter converts business objects retrieved from the associated data source to table rows. The new representation objects are created by a representation object factory. The factory interface varies according to the type of adapter. The table adapter uses by default an IlpTableRowFactory that creates representation objects of type IlpDefaultTableRow.

Editing

Adapter interfaces are read-only, meaning that they do not perform editing operations on the representation objects they create.