ImagingTools Core SDK
Public Member Functions | List of all members
imtbase::COrderedObjectCollectionProxy

#include <COrderedObjectCollectionProxy.h>

Inheritance diagram for imtbase::COrderedObjectCollectionProxy:
imtbase::IOrderedObjectCollection imtbase::IObjectCollection imtbase::IObjectCollectionInfo imtbase::ICollectionInfo

Public Member Functions

 COrderedObjectCollectionProxy (IObjectCollection *collectionPtr, bool takeOwnership=false)
 
- Public Member Functions inherited from imtbase::IObjectCollection
template<typename Interface >
const Interface * GetObjectPtr (const Id &objectId) const
 
virtual void ResetObjectIds ()
 

Additional Inherited Members

- Public Types inherited from imtbase::IObjectCollection
enum  OperationalFlags {
  OF_SUPPORT_RENAME = 1 , OF_SUPPORT_INSERT = 2 , OF_SUPPORT_DELETE = 4 , OF_SUPPORT_EDIT = 8 ,
  OF_SUPPORT_USING = 16 , OF_SUPPORT_PAGINATION = 32 , OF_ALL = OF_SUPPORT_RENAME | OF_SUPPORT_INSERT | OF_SUPPORT_DELETE | OF_SUPPORT_EDIT | OF_SUPPORT_USING | OF_SUPPORT_PAGINATION
}
 
- Public Types inherited from imtbase::ICollectionInfo
enum  ChangeFlags {
  CF_ADDED = 10000 , CF_ELEMENT_RENAMED , CF_ELEMENT_DESCRIPTION_CHANGED , CF_ELEMENT_STATE ,
  CF_REMOVED , CF_RESTORED , CF_LAST
}
 
enum  ElementInfoType { EIT_NAME , EIT_DESCRIPTION , EIT_ENABLED , EIT_USER = 1000 }
 
enum  MetaInfoType {
  MIT_INSERTION_USER = idoc::IDocumentMetaInfo::MIT_USER + 10000 , MIT_INSERTION_TIME , MIT_LAST_OPERATION_USER , MIT_LAST_OPERATION_TIME ,
  MIT_PREVIEW_THUMBNAIL , MIT_REVISION = idoc::IDocumentMetaInfo::MIT_USER + 20000
}
 

Detailed Description

Implementation of an ordered object collection facade. This class wraps an existing IObjectCollection and maintains a custom ordering for its items. Uses composition (aggregation) to delegate operations to the wrapped collection.

Note
Change Notification: The proxy uses imod::CModelUpdateBridge to forward change notifications from the aggregated collection to observers of the proxy. When the underlying collection changes, observers of the proxy are automatically notified.
The proxy automatically synchronizes the custom order with the aggregated collection's current state. If items are added or removed from the aggregated collection, the custom order will be updated when GetOrderedItemIds() or GetElementIds() is called.
Ownership: The proxy uses istd::TOptInterfacePtr which supports both managed (owned) and unmanaged (non-owned) pointers. Use the takeOwnership parameter to control ownership.

Definition at line 39 of file COrderedObjectCollectionProxy.h.

Constructor & Destructor Documentation

◆ COrderedObjectCollectionProxy()

imtbase::COrderedObjectCollectionProxy::COrderedObjectCollectionProxy ( IObjectCollection collectionPtr,
bool  takeOwnership = false 
)
explicit

Constructor.

Parameters
collectionPtrPointer to the collection to wrap (must not be null).
takeOwnershipIf true, proxy takes ownership; if false, caller manages lifetime (default: false).