Release 10.1A: OpenEdge Development:
Java Open Clients

> ## Methods

> The `ProDataGraphMetaData` class provides the following methods.

> ##### addTable( )

> Adds the specified temp-table schema definition (`ProDataObject` meta data) to the `ProDataGraphMetaData` object:

> Syntax
>     void addTable(ProDataObjectMetaData tablemd)

> ``tablemd``

> Specifies a `ProDataObjectMetaData` object that defines the schema of a temp-table in a `ProDataGraph`.

> You must call this method to define each required `ProDataObject` collection before attaching this `ProDataGraphMetaData` object to the `ProDataGraph`. Each `ProDataObjectMetaData` object describes the meta data for `ProDataObject` instances in a collection that maps to a temp-table in the corresponding Progress 4GL ProDataSet. When you call `ProDataGraph.createProDataObject()`, a OpenEdge returns a `ProDataObject` that contains column and type data as described by the corresponding `ProDataObjectMetaData` object.

> ##### addDataRelation( )

> Adds the specified data-relation definition to the `ProDataGraphMetaData` object:

> Syntax
>     void addDataRelation (ProDataRelatonMetaData drmd)

> ``drmd``

> Specifies a `ProDataRelationMetaData` object that defines a data-relation for a `ProDataGraph`.

> You can only call this method after you have already called the `addTable()` method to define the `ProDataObject` collections that participate in the specified data-relation. You must also call this method to define each required data-relation before attaching this `ProDataGraphMetaData` object to the `ProDataGraph`. This method throws an `Exception` if any table participating in the specified data-relation is not already a member of the `ProDataGraphMetaData`.

> ##### getNumTables( )

> Returns the number of `ProDataObjectMetaData` objects defined in this `ProDataGraphMetaData` object:

> Syntax
>     int getNumTables()

> ##### getTableNames( )

> Returns a `String` array of the table names of the `ProDataObjectMetaData` objects defined in this `ProDataGraphMetaData` object:

> Syntax
>     java.lang.String[] getTableNames()

> ##### getNumRelations( )

> Returns the number of `ProDataRelationMetaData` objects in this `ProDataGraphMetaData` object:

> Syntax
>     int getNumRelations()

> ##### getTableMetaData( )

> Returns the specified `ProDataObjectMetaData` object in this `ProDataGraphMetaData` object:

> Syntax
>     ProDataObjectMetaData getTableMetaData(int idx)

> ``idx``

> Specifies a 0-based index of tables that can also reference an item in the array of table names returned by the getTableNames( ) method up to the limit specified by the getNumTables( ) method.

> ##### getRelationMetaData( )

> Returns the specified `ProDataRelationMetaData` object in this `ProDataGraphMetaData` object:

> Syntax
>     ProDataRelationMetaData getRelationMetaData(int idx)

> ``idx``

> Specifies a 0-based index of data-relations up to the limit specified by the getNumRelations( ) method.

Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095