Package commonj.sdo

Examples of commonj.sdo.DataGraph


    return null;
  }
 
  public static ChangeSummary getChangeSummary(DataObject dataObject)
  {
    DataGraph dataGraph = getDataGraph(dataObject);
    if (dataGraph != null)
    {
      return dataGraph.getChangeSummary();
    }
    else
    {
      for (DataObject csDataObject = dataObject; csDataObject != null; csDataObject = csDataObject.getContainer())
      {
View Full Code Here


    }
  }
 
  public static Type getType(DataObject dataObject, String namespaceURI, String typeName)
  {
    DataGraph dataGraph = dataObject.getDataGraph();
    if (dataGraph != null)
    {
      return dataGraph.getType(namespaceURI, typeName);
    }
    else
    {
      //TODO think about where else to find the type
      return TypeHelper.INSTANCE.getType(namespaceURI, typeName);
View Full Code Here

      return target;
    }
   
    protected void writeDataObject(DataObject dataObject, ObjectOutput objectOutput) throws IOException
    {
      DataGraph dataGraph = dataObject.getDataGraph();
      if (dataGraph != null)
      {
        objectOutput.writeByte(0);
        objectOutput.writeUTF(SDOUtil.getXPath(dataObject));
        objectOutput.writeObject(dataGraph);
View Full Code Here

    return null;
  }
 
  public static ChangeSummary getChangeSummary(DataObject dataObject)
  {
    DataGraph dataGraph = getDataGraph(dataObject);
    if (dataGraph != null)
    {
      return dataGraph.getChangeSummary();
    }
    else
    {
      for (DataObject csDataObject = dataObject; csDataObject != null; csDataObject = csDataObject.getContainer())
      {
View Full Code Here

    }
  }
 
  public static Type getType(DataObject dataObject, String namespaceURI, String typeName)
  {
    DataGraph dataGraph = dataObject.getDataGraph();
    if (dataGraph != null)
    {
      return dataGraph.getType(namespaceURI, typeName);
    }
    else
    {
      //TODO think about where else to find the type
      return TypeHelper.INSTANCE.getType(namespaceURI, typeName);
View Full Code Here

   * <!-- end-user-doc -->
   * @generated
   */
  public NotificationChain basicSetEDataGraph(DataGraph newEDataGraph, NotificationChain msgs)
  {
    DataGraph oldEDataGraph = eDataGraph;
    eDataGraph = newEDataGraph;
    if (eNotificationRequired())
    {
      ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SDOPackage.CHANGE_SUMMARY__EDATA_GRAPH, oldEDataGraph, newEDataGraph);
      if (msgs == null) msgs = notification; else msgs.add(notification);
View Full Code Here

     * An empty DataGraph can have a root assigned by the createRootObject() methods.
     * However, if a previous root DataObject exists than an IllegalStateException is
     * thrown.
     */
    public void testCreateRootObjectAgainIllegalStateException() {
        DataGraph dataGraph = SDOUtil.createDataGraph();
        Type type = testDO.getType();

        // verify the initial condition
        assertNull("The DataGraph should have been created without a root DataObject.", dataGraph.getRootObject());
        assertNotNull("DataObject.getType() returned null.", type);

        dataGraph.createRootObject(type);

        // verify the pre-condition
        assertNotNull("The DataGraph.createRootObject() should have created a root DataObject for the DataGraph.", dataGraph.getRootObject());

        try {
            dataGraph.createRootObject(type);
            fail("DataGraph.createRootObject(Type) should throw an IllegalStateException a root Object already exists for the DataGraph.  No Exception was thrown.");
        } catch (IllegalStateException e) {
            // Success - do nothing
        } catch (Exception e) {
            fail("DataGraph.createRootObject(Type) should throw an IllegalStateException a root Object already exists for the DataGraph.  " + e.getClass().getName() + " was thrown.");
View Full Code Here

    return null;
  }
 
  public static ChangeSummary getChangeSummary(DataObject dataObject)
  {
    DataGraph dataGraph = getDataGraph(dataObject);
    if (dataGraph != null)
    {
      return dataGraph.getChangeSummary();
    }
    else
    {
      for (DataObject csDataObject = dataObject; csDataObject != null; csDataObject = csDataObject.getContainer())
      {
View Full Code Here

    }
  }
 
  public static Type getType(DataObject dataObject, String namespaceURI, String typeName)
  {
    DataGraph dataGraph = dataObject.getDataGraph();
    if (dataGraph != null)
    {
      return dataGraph.getType(namespaceURI, typeName);
    }
    else
    {
      //TODO think about where else to find the type
      return TypeHelper.INSTANCE.getType(namespaceURI, typeName);
View Full Code Here

   

    Type newt = SDOUtil.createType(hc, "testcases.changesummary", "simpleNOCS", false);
    Property strProp = SDOUtil.createProperty(newt, "strElem", strt);

    DataGraph graph = SDOUtil.createDataGraph();
    DataObject iNewt = graph.createRootObject(newt);
   
    testBasicsBody(strProp, iNewt);
}
View Full Code Here

TOP

Related Classes of commonj.sdo.DataGraph

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.