Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle TopLink
11g Release 1 (11.1.1)

E28847-01


org.eclipse.persistence.sdo.helper.jaxb
Class JAXBDataFactory

java.lang.Object
  extended by org.eclipse.persistence.sdo.helper.delegates.SDODataFactoryDelegate
      extended by org.eclipse.persistence.sdo.helper.jaxb.JAXBDataFactory

All Implemented Interfaces:
SDODataFactory

public class JAXBDataFactory
extends SDODataFactoryDelegate

This implementation of commonj.sdo.helper.DataFactory is responsible for ensuring that newly created DataObjects are assigned a JAXB aware value store.

 Type customerType = jaxbHelperContext.getType(Customer.class);
 DataObject customerDO = jaxbHelperContext.getDataFactory().create(customerType);
 customerDO.set("first-name", "Jane");
 
 Customer customer = jaxbHelperContext.unwrap(customerDO);
 customer.getFirstName();  // returns "Jane" 
 

Constructor Summary
JAXBDataFactory(HelperContext helperContext)
           

 

Method Summary
 DataObject create(Type type)
          Return a new DataObject of the specified Type.
 JAXBHelperContext getHelperContext()
          INTERNAL: Return the current helperContext associated with this delegate.

 

Methods inherited from class org.eclipse.persistence.sdo.helper.delegates.SDODataFactoryDelegate
create, setHelperContext

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

JAXBDataFactory

public JAXBDataFactory(HelperContext helperContext)

Method Detail

getHelperContext

public JAXBHelperContext getHelperContext()
Description copied from class: SDODataFactoryDelegate
INTERNAL: Return the current helperContext associated with this delegate.
Specified by:
getHelperContext in interface SDODataFactory
Overrides:
getHelperContext in class SDODataFactoryDelegate
Returns:

create

public DataObject create(Type type)
Return a new DataObject of the specified Type. If a corresponding class (based on XML schema information) exists in the JAXBContext, then the returned DataObject will wrap an instance of that class.
Overrides:
create in class SDODataFactoryDelegate

Skip navigation links

Copyright © 1998, 2012, Oracle. All Rights Reserved.