public interface UserServiceRecordFormFactory
UserService replacing
the default model-driven record form. Regarding UIForm, it allows
implementing more advanced user interfaces, for instance navigating between
multiple pages, or accessing and manipulating
multiple records and dynamic objects.
In the context of an association, the user service can be further refined by
implementing UserServiceAssociationRecordFormFactory.
The factory must be declared under the element
<osd:table>. For example:
<xs:annotation>
<xs:appinfo>
<osd:table>
<primaryKeys>/id</primaryKeys>
<recordForm osd:class="com.foo.MyFactory"/>
</osd:table>
</xs:appinfo>
</xs:annotation>
where com.foo.MyFactory is
the fully qualified name of a class implementing this interface.
The declaration may also use parameters:
<recordForm class="com.foo.MyFactory">
<param1>...</param1>
<param2>...</param2>
</recordForm>
where param1 and param2 are JavaBean properties
of the com.foo.MyFactory class.
For more information, see the JavaBean specification.
setParam1(...) and
setParam2(...));setup(UserServiceRecordFormFactoryContext)
is called for the new instance).newUserServiceForCreate(UserServiceRecordFormContext.ForCreate) is called each time
a record view must be displayed for creating a record.newUserServiceForDefault(UserServiceRecordFormContext.ForDefault) is called each time
a record view must be displayed for modifying a record.newUserServiceForDuplicate(UserServiceRecordFormContext.ForDuplicate) is called each time
a record view must be displayed for duplicating a record.UserServiceAssociationRecordFormFactory| Modifier and Type | Method and Description |
|---|---|
UserService<TableViewEntitySelection> |
newUserServiceForCreate(UserServiceRecordFormContext.ForCreate aContext)
Creates and returns a new instance of
UserService
for creating a record. |
UserService<RecordEntitySelection> |
newUserServiceForDefault(UserServiceRecordFormContext.ForDefault aSelection)
Creates and returns a new instance of
UserService
for displaying a record on consultation or on modification. |
UserService<RecordEntitySelection> |
newUserServiceForDuplicate(UserServiceRecordFormContext.ForDuplicate aSelection)
Creates and returns a new instance of
UserService
for duplicating a record. |
void |
setup(UserServiceRecordFormFactoryContext aContext)
This method is called when the data model is loaded.
|
UserService<TableViewEntitySelection> newUserServiceForCreate(UserServiceRecordFormContext.ForCreate aContext)
UserService
for creating a record.
If this method returns null, then the
default model-driven form will be used for creating a record.
ServiceKey.CREATEUserService<RecordEntitySelection> newUserServiceForDefault(UserServiceRecordFormContext.ForDefault aSelection)
UserService
for displaying a record on consultation or on modification.
If this method returns null then the
default model-driven form will be used for
displaying a record on consultation or on modification.
ServiceKey.DEFAULT_SERVICEUserService<RecordEntitySelection> newUserServiceForDuplicate(UserServiceRecordFormContext.ForDuplicate aSelection)
UserService
for duplicating a record.
If this method returns null then the
default model-driven form will be used for duplicating a record.
ServiceKey.DUPLICATEvoid setup(UserServiceRecordFormFactoryContext aContext)