Support for GeneratedRecords artifact type:
WebSphere adapters may support
JavaBeanRecord data representation along with SDO 1.0 and SDO 2.0 data objects.
As part of the support for JavaBean data representation, the adapter foundation
classes provides a JavaBeans record generator class that can generate
DataBindingDescriptions for the object types discovered and selected through the
enterprise metadata discovery (EMD) process.
Each adapter enterprise metadata discovery provides a list of artifact types it
supports, allowing the user to select an artifact type that is appropriate for their
environment. For example, to enable the adapters on runtimes where SDO
implementations are not available, users will run the ESD wizards to generate the
adapter artifacts for GeneratedRecords type. When the user selects a Generated
Records artifact type in the enterprise metadata discovery process, the external
service discovery wizard will look for a databinding generator class name on the
EMD DataDescription and invokes that class to generate the JavaBeans records.
All adapter enterprise metadata discovery that support the generated records
artifact type would need to set the data binding generator class name (on the
DataDescription) to the generator implementation provided in the AFC. Here is
code snippet showing how the record generator is set in the service description
implementation of an adapter EMD.
WBISingleValuedPropertyImpl property = (WBISingleValuedPropertyImpl) selectionProperties.getProperty
(EMDConstants.ARTIFACTS_SUPPORTED);
WBIMetadataConnectionImpl.getToolContext().getProgressMonitor().setNote("Business object definitions created");
String namespace = getNameSpace();
//Change made for making BG Optional
if (property.getValue().equals(EMDConstants.DATA_BINDINGS)) {
dataDescription.setName(WBIDataDescriptionImpl.convertNamespaceToUri(nam "/"
+ metadataObj.getBOName().toLowerCase() + "bg" ), metadataObj.getBOName() + "BG");
dataDescription.setDataBindingGeneratorClassName
("com.ibm.j2ca.sample.twineball.emd.runtime.TwineBallDataBindingGenerator");
dataDescription.setGenericDataBindingClassName(null);
}
else if (property.getValue().equals(EMDConstants.GENERATED_RECORDS)) {
dataDescription.setName(WBIDataDescriptionImpl.convertNamespaceToUri(nam "/"
+ metadataObj.getBOName().toLowerCase()), metadataObj.getBOName());
dataDescription.setDataBindingGeneratorClassName
("com.ibm.j2ca.extension.dataexchange.bean.generator.RecordGenerator");
dataDescription.setGenericDataBindingClassName(null);
} else {
//Generic Record Scenario
dataDescription.setName(WBIDataDescriptionImpl.convertNamespaceToUri(nam "/"
+ metadataObj.getBOName().toLowerCase()), metadataObj.getBOName());
dataDescription.setGenericDataBindingClassName
("com.ibm.j2ca.sample.twineball.TwineBallStructuredRecord");
New property types supported from WebSphere Adapter Toolkit V6.1:
TableProperty: A property representing a table with rows and columns. Each
column is represented by the PropertyDescriptor instance and each cell
corresponding to a given row and column is represented by a
SingleValuedProperty implementation.
TreeProperty: A property representing a tree of selectable nodes. Each node is
represented by a NodeProperty implementation which can be selected, highlighted
and can have configuration properties represented by a PropertyGroup instance.
Enterprise Metadata Discovery general interfaces and
implementation for application adapters
Enterprise metadata discovery is a
discovery service
, or a component within an
adapter that enables the generation of business object definitions and other artifacts
required by service component architecture.
WebSphere Adapter development overview
123
Summary of Contents for WebSphere Adapters
Page 2: ......
Page 6: ...iv WebSphere Adapters WebSphere Adapter Toolkit User Guide...
Page 220: ...214 WebSphere Adapters WebSphere Adapter Toolkit User Guide...
Page 224: ...218 WebSphere Adapters WebSphere Adapter Toolkit User Guide...
Page 225: ......
Page 226: ...Printed in USA...