public class P2OAccessWorker.Library
extends java.lang.Object
Constructor and Description |
---|
Library() |
Modifier and Type | Method and Description |
---|---|
boolean |
isDenormalizedProperty(java.lang.String historical)
Check if given historical fully qualified property is denormalized.
|
boolean |
isDMOInterface(java.lang.String name)
Report whether the given class name is the unqualified name of any
DMO interface, in any schema tracked by the current P2J
configuration.
|
boolean |
isDMOInterface(java.lang.String name,
java.lang.String schema)
Report whether the given class name is the unqualified name of a DMO interface, in the
schema tracked by the current P2J configuration. |
boolean |
isForeignReference(java.lang.String historical)
Report whether the given, historical table will be mapped in the
converted application to a database table which represents a foreign
reference of another table's foreign key.
|
boolean |
isValidatable(java.lang.String historical)
Indicate whether a DMO property can be validated at runtime, given
its legacy schema name.
|
java.lang.String |
javaBufferName(java.lang.String historical)
Look up the name of a Java DMO interface, given its legacy name,
and return the name of the default, implicit buffer associated with
this interface.
|
java.lang.String |
javaClassName(java.lang.String historical)
Look up the name of a Java DMO interface, given its legacy name.
|
java.lang.String |
javaGetterName(java.lang.String historical,
boolean isLogical)
Look up the name of the accessor (getter) method associated with the
DMO property which represents the specified, legacy database field.
|
java.lang.String |
javaGetterName(java.lang.String historical,
java.lang.Long index,
boolean isLogical)
Look up the name of the accessor (getter) method associated with the
DMO property which represents the specified, legacy database field.
|
java.lang.String |
javaPackage(java.lang.String historical)
Look up the package of a Java DMO interface, given its legacy name.
|
java.lang.String |
javaPropertyName(java.lang.String historical,
boolean qualified)
Look up the name of the name of the DMO property which represents
the specified, legacy database field.
|
java.lang.String |
javaPropertyName(java.lang.String historical,
boolean qualified,
java.lang.Long index)
Look up the name of the name of the DMO property which represents
the specified, legacy database field.
|
java.lang.String |
javaSetterName(java.lang.String historical)
Look up the name of the mutator (setter) method associated with the
DMO property which represents the specified, legacy database field.
|
java.lang.String |
javaSetterName(java.lang.String historical,
java.lang.Long index)
Look up the name of the mutator (setter) method associated with the
DMO property which represents the specified, legacy database field.
|
java.util.Set |
legacyFieldNames(java.lang.String historical)
Retrieve the full set of fully quallified, legacy field names for a
legacy Progress table.
|
public java.lang.String javaPackage(java.lang.String historical) throws SchemaException
historical
- Fully qualified, legacy, Progress schema name for a table.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence.public java.lang.String javaClassName(java.lang.String historical) throws SchemaException
historical
- Fully qualified, legacy, Progress schema name for a table.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the table portion of historical
cannot be
resolved to a corresponding Java name.public java.lang.String javaBufferName(java.lang.String historical) throws SchemaException
historical
- Fully qualified, legacy, Progress schema name for a table.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the table portion of historical
cannot be
resolved to a corresponding Java name.public java.lang.String javaPropertyName(java.lang.String historical, boolean qualified) throws SchemaException
historical
- Fully qualified, legacy, Progress schema name for a
database field.qualified
- true
if property name should be qualified with
a buffer name; false
if it should remain
unqualified.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the field portion of historical
cannot be
resolved to a corresponding Java name.public java.lang.String javaPropertyName(java.lang.String historical, boolean qualified, java.lang.Long index) throws SchemaException
historical
- Fully qualified, legacy, Progress schema name for a
database field.qualified
- true
if property name should be qualified with
a buffer name; false
if it should remain
unqualified.index
- Zero-based index of custom property name for denormalized field with extent,
otherwise null.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the field portion of historical
cannot be
resolved to a corresponding Java name.public java.util.Set legacyFieldNames(java.lang.String historical) throws SchemaException
historical
- Fully qualified, legacy, Progress schema name for a table.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if historical
does not represent a known table.public java.lang.String javaGetterName(java.lang.String historical, boolean isLogical) throws SchemaException
get{PropertyName}or
is{PropertyName}if PropertyName represents a
logical
data type.historical
- Fully qualified, legacy, Progress schema name for a
database field.isLogical
- true
if historical
represents a
logical
field, else false
.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the field portion of historical
cannot be
resolved to a corresponding Java name.public java.lang.String javaGetterName(java.lang.String historical, java.lang.Long index, boolean isLogical) throws SchemaException
get{PropertyName}or
is{PropertyName}if PropertyName represents a
logical
data type.historical
- Fully qualified, legacy, Progress schema name for a
database field.index
- Zero-based index of custom property name for denormalized field with extent,
otherwise null.isLogical
- true
if historical
represents a
logical
field, else false
.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the field portion of historical
cannot be
resolved to a corresponding Java name.public java.lang.String javaSetterName(java.lang.String historical) throws SchemaException
set{PropertyName}
historical
- Fully qualified, legacy, Progress schema name for a
database field.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the field portion of historical
cannot be
resolved to a corresponding Java name.public java.lang.String javaSetterName(java.lang.String historical, java.lang.Long index) throws SchemaException
set{PropertyName}
historical
- Fully qualified, legacy, Progress schema name for a
database field.index
- Zero-based index of custom property name for denormalized field with extent,
otherwise null.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence;
if the field portion of historical
cannot be
resolved to a corresponding Java name.public boolean isDenormalizedProperty(java.lang.String historical) throws SchemaException
historical
- Historical fully qualified property name.true
if given property is denormalized.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence.public boolean isValidatable(java.lang.String historical) throws SchemaException
historical
- Fully qualified, legacy Progress field name.true
if the field should be validated at
runtime, else false
.SchemaException
- if there is any error loading P2J schema configuration data;
if there is any error loading the AST from persistence.public boolean isDMOInterface(java.lang.String name) throws SchemaException
name
- An unqualified class name.true
if name
collides with any
DMO interface in any schema, else false
.SchemaException
- if there is an error loading schema names from
configuration.public boolean isDMOInterface(java.lang.String name, java.lang.String schema) throws SchemaException
schema
tracked by the current P2J configuration.name
- An unqualified class name.schema
- The name of the schema to look into.true
if name
is present as java name of a table from
the specified schema
and false
if schema
does not exist or it does not contain such interface.SchemaException
- if there is an error loading schema names from configuration.public boolean isForeignReference(java.lang.String historical) throws SchemaException
historical
- Fully qualified, legacy Progress table name.true
if the given table represents the foreign
end of a one-to-one or a one-to-many relation between two
tables.SchemaException
- if there is an error loading schema names from
configuration.