Пример #1
0
  @Override
  public synchronized EList<Adapter> eAdapters() {
    EList<Adapter> adapters = super.eAdapters();
    if (!FSMUtil.isTransient(this)) {
      InternalCDOView view = cdoView();
      for (Adapter adapter : adapters) {
        if (!(adapter instanceof CDOLegacyWrapper)) {
          view.handleAddAdapter(this, adapter);
        }
      }
    }

    return adapters;
  }
Пример #2
0
  protected void instanceToRevisionContainment() {
    InternalCDORevision revision = cdoRevision();

    CDOResource resource = (CDOResource) getInstanceResource(instance);
    revision.setResourceID(resource == null ? CDOID.NULL : resource.cdoID());

    InternalEObject eContainer = getInstanceContainer(instance);
    if (eContainer == null) {
      revision.setContainerID(CDOID.NULL);
      revision.setContainingFeatureID(0);
    } else {
      CDOObject cdoContainer = FSMUtil.adapt(eContainer, viewAndState.view);
      revision.setContainerID(cdoContainer);
      revision.setContainingFeatureID(getInstanceContainerFeatureID(instance));
    }
  }