Public Member Functions | |
DataField | addDataField (String sName) throws TFormerException |
Creates and adds a DataField to the Project. | |
DataSource | addDataSource (DataSourceType type, String name) throws TFormerException |
Creates and adds a DataSource to the Project. | |
FormLayout | addFormLayout (String sName) throws TFormerException |
Creates and adds a FormLayout to the Project. | |
void | dispose () throws TFormerException |
Releases the resources allocated into TFORMer runtime by this instance. | |
void | dump (PrintStream s) throws IOException, TFormerException |
Dumps the current instance into a text stream. | |
String | getComment () throws TFormerException |
Gets the comment for the Project. | |
DataField | getDataField (String name) throws TFormerException |
Gets the DataField information from the Project. | |
DataSource | getDataSource (String name) throws TFormerException |
Gets the DataSource information from the Project. | |
String | getDefaultDirectory () throws TFormerException |
Gets the default directory of the Project. | |
String | getDescription () throws TFormerException |
Gets the description of the Project. | |
DataField | getFirstDataField () throws TFormerException |
Gets the first DataField of the Project and returns a DataField object. | |
DataSource | getFirstDataSource () throws TFormerException |
Gets the first DataSource defined in the Project. | |
FormLayout | getFirstFormLayout () throws TFormerException |
Gets the first FormLayout of the Project and returns a FormLayout object. | |
FormLayout | getFormLayout (String sName) throws TFormerException |
Gets the FormLayout information from the Project. | |
String | getName () throws TFormerException |
Gets the name of the Project. | |
Project | getNext () throws TFormerException |
Gets the next Project defined in the Repository. | |
int | getNumberOfDataFields () throws TFormerException |
Gets the number of DataFields of the calling Project. | |
int | getNumberOfDataSources () throws TFormerException |
Gets the number of DataSources of the calling Project. | |
int | getNumberOfFormLayouts () throws TFormerException |
Gets the number of Forms of the calling Project. | |
Repository | getRepository () |
Return the repository in which the project is defined. | |
void | removeDataField (String name) throws TFormerException |
Removes a DataField from the Project by name. | |
void | removeDataField (DataField field) throws TFormerException |
Removes a DataField from the Project. | |
void | removeDataSource (String name) throws TFormerException |
Removes the DataSource from the Project by name. | |
void | removeDataSource (DataSource dataSource) throws TFormerException |
Removes the DataSource from the Project. | |
void | removeFormLayout (String name) throws TFormerException |
Removes a Form from the Project by name. | |
void | removeFormLayout (FormLayout form) throws TFormerException |
Removes a Form from the Project. | |
void | setComment (String sComment) throws TFormerException |
Sets the comment for the Project. | |
void | setDescription (String sDescription) throws TFormerException |
Sets the description of the Project. | |
void | setName (String sName) throws TFormerException |
Sets or sets the name of the Project. | |
String | toString () |
Returns a string representation of the instance. |
This class is used to retrieve or set information belonging to a user-defined Project or to the GlobalProject .
Project-objects are used in a Repository. The GlobalProject is available for repositories as well as for stand-alone form-layouts:
Type | Description
|
---|---|
Repository | A Project is used by the user to divide a Repository into logical units. Each Project holds a set of DataField-objects. Data-fields defined within a Project are usable exclusively by form-layouts which are member of this Project. Beside the user-defined Project-objects a Repository contains one Repository.GlobalProject by default. This Repository.GlobalProject is only used for defining system-wide data-fields, it can not store a reference to a FormLayout. |
Stand-Alone FormLayout | A stand-alone FormLayout can be imagined like a very simple type of Repository. This simplified Repository contains exactly one Repository.GlobalProject which stores the DataField-definitions and the FormLayout itself. User-defined Project-objects are not supported by a stand-alone FormLayout. |
In order to access the data-fields in a Project you may either use the method GetDataField or you may iterate through all available data-fields using FirstDataField and DataField. DataField.Next (please check out the respective examples).
If you want to know, whether the returned DataField is actually used in a FormLayout you can use the method FormLayout.getDataFieldUsage.
Important: The Project is only valid as long as it is available in the Repository. If it is removed from the Repository all instances of the Project immediately become invalid.
A single instance of this class must not be used by different threads.
DataField addDataField | ( | String | sName | ) | throws TFormerException |
DataSource addDataSource | ( | DataSourceType | type, | |
String | name | |||
) | throws TFormerException |
Creates and adds a DataSource to the Project.
name | The name of the DataSource to be added to the Project. | |
type | The type of the DataSource. |
TFormerException |
FormLayout addFormLayout | ( | String | sName | ) | throws TFormerException |
Creates and adds a FormLayout to the Project.
sName | The name of the FormLayout to be added to the Project. |
TFormerException |
void dispose | ( | ) | throws TFormerException |
Releases the resources allocated into TFORMer runtime by this instance.
Remember to call this method always after the use of the instance, in order to release the memory allocated.
TFormerException | error occurred into TFORMer runtime. |
void dump | ( | PrintStream | s | ) | throws IOException, TFormerException |
Dumps the current instance into a text stream.
s | instance of the stream |
IOException | error in I/O | |
TFormerException | error occurred into TFORMer runtime. |
String getComment | ( | ) | throws TFormerException |
Gets the comment for the Project.
TFormerException | if an error occurs |
DataField getDataField | ( | String | name | ) | throws TFormerException |
DataSource getDataSource | ( | String | name | ) | throws TFormerException |
Gets the DataSource information from the Project.
name | The name of the DataSource to be retrieved from the Project. |
null
if the requested object doesn't exist, otherwise a valid instance TFormerException | if an error occurs or the specified DataSource does not exist |
String getDefaultDirectory | ( | ) | throws TFormerException |
Gets the default directory of the Project.
TFormerException | if an error occurs |
String getDescription | ( | ) | throws TFormerException |
Gets the description of the Project.
TFormerException | if an error occurs |
DataField getFirstDataField | ( | ) | throws TFormerException |
DataSource getFirstDataSource | ( | ) | throws TFormerException |
Gets the first DataSource defined in the Project.
TFormerException | if an error occurs |
FormLayout getFirstFormLayout | ( | ) | throws TFormerException |
Gets the first FormLayout of the Project and returns a FormLayout object.
null
if not exists TFormerException |
FormLayout getFormLayout | ( | String | sName | ) | throws TFormerException |
Gets the FormLayout information from the Project.
sName | The name of the FormLayout to be retrieved from the Project. |
null
if the requested object doesn't exist, otherwise a valid instance TFormerException | error occurs in TFORMer runtime |
String getName | ( | ) | throws TFormerException |
Gets the name of the Project.
TFormerException | if an error occurs |
Project getNext | ( | ) | throws TFormerException |
Gets the next Project defined in the Repository.
A Repository stores a list of Project objects. You can use this method to iterate through the list. To retrieve the first Project in the Repository see FirstProject.
The property is null if there are no further objects available.
TFormerException | if an error occurs |
int getNumberOfDataFields | ( | ) | throws TFormerException |
Gets the number of DataFields of the calling Project.
TFormerException |
int getNumberOfDataSources | ( | ) | throws TFormerException |
Gets the number of DataSources of the calling Project.
TFormerException |
int getNumberOfFormLayouts | ( | ) | throws TFormerException |
Gets the number of Forms of the calling Project.
TFormerException |
void removeDataField | ( | String | name | ) | throws TFormerException |
Removes a DataField from the Project by name.
name | Name of the datafield |
TFormerException |
void removeDataField | ( | DataField | field | ) | throws TFormerException |
Removes a DataField from the Project.
field | DataField to be removed |
TFormerException |
void removeDataSource | ( | String | name | ) | throws TFormerException |
Removes the DataSource from the Project by name.
name | The name of the DataSource to be removed from the Project. |
TFormerException |
void removeDataSource | ( | DataSource | dataSource | ) | throws TFormerException |
Removes the DataSource from the Project.
dataSource | The DataSource to be removed from the Project. |
TFormerException |
void removeFormLayout | ( | String | name | ) | throws TFormerException |
Removes a Form from the Project by name.
name | of the Form to be removed |
TFormerException |
void removeFormLayout | ( | FormLayout | form | ) | throws TFormerException |
Removes a Form from the Project.
form | FormLayout to be removed |
TFormerException |
void setComment | ( | String | sComment | ) | throws TFormerException |
Sets the comment for the Project.
sComment | The comment for the Project. if an error occurs |
TFormerException |
void setDescription | ( | String | sDescription | ) | throws TFormerException |
Sets the description of the Project.
sDescription | The description of the Project. |
TFormerException | if an error occurs |
void setName | ( | String | sName | ) | throws TFormerException |
Sets or sets the name of the Project.
sName | The name of the Project. |
TFormerException | if an error occurs |
String toString | ( | ) |
Returns a string representation of the instance.
© 2006-2009 All rights reserved by TEC-IT Datenverarbeitung GmbH |
![]() |
Generated on Wed Sep 2 16:01:28 2009 for TFORMer Runtime JAVA Developer Reference with doxygen 1.5.8 |