Interface ModelObject
- All Superinterfaces:
CanRender<Renderer<? extends Renderer<?>>>,HasFields,HasReference<ModelEntityReference>,ModelEntity
- All Known Subinterfaces:
Baseline,BaselineCollection,Category,Document,ModelObjectBase<T,,R> Plan,Project,RichPage,Script,TestRun,TimePoint,UpdatableBaseline,UpdatableBaselineCollection,UpdatableCategory,UpdatableDocument,UpdatableModelObject,UpdatableModelObjectBase<T,,R> UpdatablePlan,UpdatableProject,UpdatableRichPage,UpdatableScript,UpdatableTestRun,UpdatableTimePoint,UpdatableUser,UpdatableUserGroup,UpdatableWikiPage,UpdatableWorkItem,User,UserGroup,WikiPage,WorkItem
- Since:
- 3.9.0
-
Method Summary
Modifier and TypeMethodDescriptioncan()copyFieldsTo(UpdatableModelObject target) fields()voidforget()getFromRevision(String revision) Returns the object from a specified revision.com.polarion.platform.persistence.model.IPObjectReturns a reference including the requested and actual revisions.Returns a reference to the current (latest) revision of this object, which means that it has alwaysnullrequested revision, even if this object was requested from some revision.getUpdatable(WriteTransaction transaction) IterableWithSize<? extends ModelObjectReference> history()Returns history of object.label()Returns some non empty user friendly label of the object.voidresolve()Methods inherited from interface com.polarion.alm.shared.api.model.ModelEntity
equals, hashCode, isUnresolvable, render, transaction
-
Method Details
-
getReference
Returns a reference including the requested and actual revisions.- Specified by:
getReferencein interfaceHasReference<ModelEntityReference>
-
getReferenceToCurrent
Returns a reference to the current (latest) revision of this object, which means that it has alwaysnullrequested revision, even if this object was requested from some revision.This method should be used to obtain the current reference of an object, as it correctly reflects the object's current location, even if it has been renamed or moved since the reference was last obtained.
This method must be used over
ModelObjectReference.getWithRevision(String)withnull, orModelObjectReference.getCurrent(), both of which retain the path stored in the reference and do not account for renames or moves. -
getFromRevision
Returns the object from a specified revision. This method will correctly resolve renamed/moved objects. If the revision is null, it returns the latest object.- Parameters:
revision- the revision from which to get the object, or null for the current revision.- Returns:
- the object at the specified revision.
- Since:
- 3.26.6
-
history
Returns history of object. If object is versioned (has requested revision) then history up to this revision will be returned. The history list is sorted from the oldest (coming first) to the newest (last). -
fields
-
resolve
void resolve() -
forget
void forget() -
can
- Specified by:
canin interfaceModelEntity- Since:
- 3.9.1
-
getOldApi
@NotNull @GwtIncompatible com.polarion.platform.persistence.model.IPObject getOldApi() -
label
Returns some non empty user friendly label of the object. It does not throw exception when the object is unresolvable or user has no permission to read it, but instead just returns the id.- Since:
- 3.9.2
-