Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 362388

Summary: Add CDORevisionManager.getObjectType() with demand loading
Product: [Modeling] EMF Reporter: Eike Stepper <stepper>
Component: cdo.coreAssignee: Eike Stepper <stepper>
Status: CLOSED FIXED QA Contact: Eike Stepper <stepper>
Severity: enhancement    
Priority: P3 CC: andy.rytina
Version: 4.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard: Lighter, Faster and Better

Description Eike Stepper CLA 2011-10-29 03:37:16 EDT
Add this method:

  /**
   * Returns the {@link CDORevision#getEClass() type} of an object.
   * <p>
   * If no revision for that object is found in the revision cache the following is tried:
   * <ol>
   * <li>If <code>branchManagerForLoadOnDemand</code> is not <code>null</code> the first revision of the object in the
   * main branch is loaded from the server and its type is returned.
   * <li>Otherwise (i.e., if <code>branchManagerForLoadOnDemand</code> is <code>null</code> or the object does not
   * exist) <code>null</code> is returned.
   * </ol>
   * <p>
   * A {@link CDOBranchManager branch manager} is required instead of just a boolean value to specify whether to
   * demand-load or not because this revision manager must be able to access the
   * {@link CDOBranchManager#getMainBranch() main branch} while demand-loading.
   * 
   * @see EObject#eClass()
   * @see #getObjectType(CDOID)
   * @since 4.1
   */
  public EClass getObjectType(CDOID id, CDOBranchManager branchManagerForLoadOnDemand);
Comment 1 Eike Stepper CLA 2011-10-29 03:54:45 EDT
commit d73f50ee911239842af196261175cfea7d227b62
Comment 2 Eike Stepper CLA 2013-06-27 03:27:53 EDT
Available in R20130213-0014 (4.1.2)