Examples of replaceFields()


Examples of com.sun.jdori.StateManagerInternal.replaceFields()

        // fetch attributes into StateManager
      JDOClass jdoClass = Helper.getJDOClass(pc.getClass());
      fieldNums = jdoClass.getManagedFieldNumbers();

      FieldManager fm = new OjbFieldManager(pc, broker);
      smi.replaceFields(fieldNums, fm);
      smi.retrieve();
     
      // get JDO PersistencecCapable instance from SM and add it to result collection
      Object instance = smi.getObject();
      result.add(instance);
View Full Code Here

Examples of com.sun.jdori.StateManagerInternal.replaceFields()

        // fetch attributes into StateManager
      JDOClass jdoClass = Helper.getJDOClass(pc.getClass());
      fieldNums = jdoClass.getManagedFieldNumbers();

      FieldManager fm = new OjbFieldManager(pc, broker);
      smi.replaceFields(fieldNums, fm);
      smi.retrieve();
     
      // get JDO PersistencecCapable instance from SM and add it to result collection
      Object instance = smi.getObject();
      result.add(instance);
View Full Code Here

Examples of org.datanucleus.StateManager.replaceFields()

        esm.getClassMetaData().getAllMemberPositions(),
        ammd.getEmbeddedMetaData());
    AbstractMemberMetaDataProvider ammdProvider = getEmbeddedAbstractMemberMetaDataProvider(mappingConsumer);
    fieldManagerStateStack.addFirst(new FieldManagerState(esm, ammdProvider, mappingConsumer, true));
    AbstractClassMetaData acmd = esm.getClassMetaData();
    esm.replaceFields(acmd.getAllMemberPositions(), this);
    fieldManagerStateStack.removeFirst();
    return esm.getObject();
  }

  /**
 
View Full Code Here

Examples of org.datanucleus.state.ObjectProvider.replaceFields()

      // Embedded persistable object
      ObjectProvider embeddedOP = getEmbeddedObjectProvider(mmd.getType(), fieldNumber, null);

      fieldManagerStateStack.addFirst(new FieldManagerState(embeddedOP, mmd.getEmbeddedMetaData()));
      try {
        embeddedOP.replaceFields(embeddedOP.getClassMetaData().getAllMemberPositions(), this);

        // Checks for whether the member values imply a null object
        if (mmd.getEmbeddedMetaData() != null && mmd.getEmbeddedMetaData().getNullIndicatorColumn() != null) {
          String nullColumn = mmd.getEmbeddedMetaData().getNullIndicatorColumn();
          String nullValue = mmd.getEmbeddedMetaData().getNullIndicatorValue();
View Full Code Here

Examples of org.datanucleus.state.ObjectProvider.replaceFields()

          }

          ObjectProvider embeddedOP = getEmbeddedObjectProvider(elementCls, fieldNumber, null);
          fieldManagerStateStack.addFirst(new FieldManagerState(embeddedOP, embmd, i));
          try {
            embeddedOP.replaceFields(embeddedOP.getClassMetaData().getAllMemberPositions(), this);
          } finally {
            fieldManagerStateStack.removeFirst();
          }
          coll.add(embeddedOP.getObject());
        }
View Full Code Here

Examples of org.datanucleus.state.ObjectProvider.replaceFields()

          }

          ObjectProvider embeddedOP = getEmbeddedObjectProvider(elementCls, fieldNumber, null);
          fieldManagerStateStack.addFirst(new FieldManagerState(embeddedOP, embmd, i));
          try {
            embeddedOP.replaceFields(embeddedOP.getClassMetaData().getAllMemberPositions(), this);
          } finally {
            fieldManagerStateStack.removeFirst();
          }
          Array.set(value, i, embeddedOP.getObject());
        }
View Full Code Here

Examples of org.datanucleus.store.ObjectProvider.replaceFields()

                return null;
            }

            ObjectProvider embSM = ec.newObjectProviderForEmbedded(embMmd, embcmd, sm, fieldNumber);
            FieldManager ffm = new FetchEmbeddedFieldManager(embSM, dbObject, embMmd);
            embSM.replaceFields(embcmd.getAllMemberPositions(), ffm);
            return embSM.getObject();
        }

        String fieldName = MongoDBUtils.getFieldName(ownerMmd, fieldNumber);
        if (!dbObject.containsField(fieldName))
View Full Code Here

Examples of org.datanucleus.store.ObjectProvider.replaceFields()

                    DBObject embeddedValue = (DBObject)dbObject.get(fieldName);
                    ObjectProvider embSM = ec.newObjectProviderForEmbedded(mmd, embcmd, sm, fieldNumber);
                    FetchFieldManager ffm = new FetchFieldManager(embSM, embeddedValue, embcmd);
                    ffm.ownerMmd = mmd;
                    ffm.embedded = true;
                    embSM.replaceFields(embcmd.getAllMemberPositions(), ffm);
                    return embSM.getObject();
                }
                else
                {
                    // Flat embedding as fields of the owning document
View Full Code Here

Examples of org.datanucleus.store.ObjectProvider.replaceFields()

                        return null;
                    }

                    ObjectProvider embSM = ec.newObjectProviderForEmbedded(mmd, embcmd, sm, fieldNumber);
                    FieldManager ffm = new FetchEmbeddedFieldManager(embSM, dbObject, mmd);
                    embSM.replaceFields(embcmd.getAllMemberPositions(), ffm);
                    return embSM.getObject();
                }
            }
            else if (Relation.isRelationMultiValued(relationType))
            {
View Full Code Here

Examples of org.datanucleus.store.ObjectProvider.replaceFields()

                        ObjectProvider embSM = ec.newObjectProviderForEmbedded(mmd, elemCmd, sm, fieldNumber);
                        embSM.setPcObjectType(ObjectProvider.EMBEDDED_COLLECTION_ELEMENT_PC);
                        FetchFieldManager ffm = new FetchFieldManager(embSM, elementObj, elemCmd);
                        ffm.ownerMmd = mmd;
                        ffm.embedded = true;
                        embSM.replaceFields(elemCmd.getAllMemberPositions(), ffm);
                        coll.add(embSM.getObject());
                    }

                    if (sm != null)
                    {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.