Mark for creation all newly introduced dependent references.
Mark for deletion all nullified dependent references.
@return the list of created objects
347429
private ArrayList handleDependentReferences(Identity oid, Object userObject,
            Object[] origFields, Object[] newFields, Object[] newRefs)
            throws LockingException
    {
        ClassDescriptor mif = _pb.getClassDescriptor(userObject.getClass());
        FieldDescriptor[] fieldDescs = mif.getFieldDescriptions();
        Collection refDescs = mif.getObjectReferenceDescriptors();
        int count = 1 + fieldDescs.length;
        ArrayList newObjects = new ArrayList();
        int countRefs = 0;

        for (Iterator it = refDescs.iterator(); it.hasNext(); count++, countRefs++)
        {
            ObjectReferenceDescriptor rds = (ObjectReferenceDescriptor) it.next();
            Identity origOid = (origFields == null ? null : (Identity) origFields[count]);
            Identity newOid = (Identity) newFields[count];

            if (rds.getOtmDependent())
            {
                if ((origOid == null) && (newOid != null))
                {
                    ContextEntry entry = (ContextEntry) _objects.get(newOid);

                    if (entry == null)
                    {
                        Object relObj = newRefs[countRefs];
                        insertInternal(newOid, relObj, LockType.WRITE_LOCK,
                                       true, oid, new Stack());
                        newObjects.add(newOid);
                    }
                }
                else if ((origOid != null) &&
                         ((newOid == null) || !newOid.equals(origOid)))
                {
                    markDelete(origOid, oid, false);
                }
            }
        }

        return newObjects;
    }
1164854
public final Record makeReferenceRecord()
    {
        if (m_recordReference != null)
            return m_recordReference;       // It already exists
        RecordOwner recordOwner = null;
        if (this.getRecord() != null)
            recordOwner = Record.findRecordOwner(this.getRecord());    // This way the record has access to the correct environment.
        this.setReferenceRecord(this.makeReferenceRecord(recordOwner));
        return m_recordReference;
    }
1360189
public List<PartialResponseDeleteType<PartialResponseChangesType<T>>> getAllDelete()
   {
      List<PartialResponseDeleteType<PartialResponseChangesType<T>>> list = new ArrayList<PartialResponseDeleteType<PartialResponseChangesType<T>>>();
      List<Node> nodeList = childNode.get("delete");
      for(Node node: nodeList)
      {
         PartialResponseDeleteType<PartialResponseChangesType<T>>  type = new PartialResponseDeleteTypeImpl<PartialResponseChangesType<T>>(this, "delete", childNode, node);
         list.add(type);
      }
      return list;
   }
595780
public List<EjbLocalRefType<WebFragmentType<T>>> getAllEjbLocalRef()
   {
      List<EjbLocalRefType<WebFragmentType<T>>> list = new ArrayList<EjbLocalRefType<WebFragmentType<T>>>();
      List<Node> nodeList = childNode.get("ejb-local-ref");
      for(Node node: nodeList)
      {
         EjbLocalRefType<WebFragmentType<T>>  type = new EjbLocalRefTypeImpl<WebFragmentType<T>>(this, "ejb-local-ref", childNode, node);
         list.add(type);
      }
      return list;
   }
440374
public List<?> getNotSelected() {
		List options = getOptions();
		if (options == null || options.isEmpty()) {
			return Collections.EMPTY_LIST;
		}

		List notSelected = new ArrayList(options);
		notSelected.removeAll(getSelected());
		return Collections.unmodifiableList(notSelected);
	}
128980
public Decorators<BeansDescriptor> getOrCreateDecorators()
   {
      Node node = model.getOrCreate("decorators");
      Decorators<BeansDescriptor> decorators = new DecoratorsImpl<BeansDescriptor>(this, "decorators", model, node);
      return decorators;
   }
782056
public BatchArtifactRef<BatchXMLDescriptor> getOrCreateRef()
   {
      List<Node> nodeList = model.get("ref");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new BatchArtifactRefImpl<BatchXMLDescriptor>(this, "ref", model, nodeList.get(0));
      }
      return createRef();
   }
610277
@Override
    public List<String> getManagedObjects() {
        ArrayList<String> managedObjects = new ArrayList<String>();
        if (this.application != null) {
            managedObjects.addAll(application.getManagedObjects());
        }
        if (this.factory != null) {
            managedObjects.addAll(factory.getManagedObjects());
        }
        if (this.lifecycle != null) {
            managedObjects.addAll(lifecycle.getManagedObjects());
        }
        return managedObjects;
    }
440341
public List<FacesConfigReferencedBeanType<FacesConfigType<T>>> getAllReferencedBean()
   {
      List<FacesConfigReferencedBeanType<FacesConfigType<T>>> list = new ArrayList<FacesConfigReferencedBeanType<FacesConfigType<T>>>();
      List<Node> nodeList = childNode.get("referenced-bean");
      for(Node node: nodeList)
      {
         FacesConfigReferencedBeanType<FacesConfigType<T>>  type = new FacesConfigReferencedBeanTypeImpl<FacesConfigType<T>>(this, "referenced-bean", childNode, node);
         list.add(type);
      }
      return list;
   }
1215050
public List<T> getEntireList() {
		InnerList iList = ref.get();
		return iList != null ? iList.getList() : null;
	}
629846
public SyntheticStorableReferenceAccess<S> getReferenceAccess() {
        if (mReferenceAccess == null) {
            Class<? extends Storable> referenceClass = mBuilder.getStorableClass();
            mReferenceAccess = new SyntheticStorableReferenceAccess<S>
                (mMasterStorableClass, referenceClass, this);
        }
        return mReferenceAccess;
    }
1030801
ImmutableCollection<Require> getKnownRequires() {
    return concat(
        dependencyInfo != null ? dependencyInfo.getRequires() : ImmutableList.of(), extraRequires);
  }
1256162
public List<Excerpt> getGeneratedBuilderAnnotations() {
    if (generatedBuilderAnnotations instanceof ImmutableList) {
      generatedBuilderAnnotations = new ArrayList<>(generatedBuilderAnnotations);
    }
    return Collections.unmodifiableList(generatedBuilderAnnotations);
  }
1251421
public Map<String, Object> getNamedBindings() {
    ImmutableMap.Builder<String, Object> builder = ImmutableSortedMap.naturalOrder();
    for (Map.Entry<String, Binding> binding : namedBindings.entrySet()) {
      builder.put(binding.getKey(), binding.getValue().getCursorOrValue());
    }
    return builder.build();
  }
1030716
public List<OneToMany<Attributes<T>>> getAllOneToMany()
   {
      List<OneToMany<Attributes<T>>> list = new ArrayList<OneToMany<Attributes<T>>>();
      List<Node> nodeList = childNode.get("one-to-many");
      for(Node node: nodeList)
      {
         OneToMany<Attributes<T>>  type = new OneToManyImpl<Attributes<T>>(this, "one-to-many", childNode, node);
         list.add(type);
      }
      return list;
   }
286143
public List<BatchArtifactRef<BatchArtifacts<T>>> getAllRef()
   {
      List<BatchArtifactRef<BatchArtifacts<T>>> list = new ArrayList<BatchArtifactRef<BatchArtifacts<T>>>();
      List<Node> nodeList = childNode.get("ref");
      for(Node node: nodeList)
      {
         BatchArtifactRef<BatchArtifacts<T>>  type = new BatchArtifactRefImpl<BatchArtifacts<T>>(this, "ref", childNode, node);
         list.add(type);
      }
      return list;
   }
665993
Iterable<Object> getHardReferences() {
        final List<Object> references = new ArrayList<Object>(hardReferences.size());
        for (final HardReference reference : hardReferences) {
            references.add(reference.referenceToKeep);
        }
        return references;
    }