Public Types | Public Member Functions | List of all members
iprm::IParamsManager Class Referenceabstract

Manager of parameters set. More...

#include <IParamsManager.h>

Inheritance diagram for iprm::IParamsManager:
iprm::ISelectionParam iser::ISerializable istd::IChangeable istd::IPolymorphic iprm::CParamsManagerCompBase iprm::CMultiParamsManagerComp iprm::CParamsManagerComp

Public Types

enum  ParamsOperationFlags {
  MF_COUNT_FIXED = 1, MF_SUPPORT_RENAME = 2, MF_SUPPORT_INSERT = 4, MF_SUPPORT_DELETE = 8,
  MF_SUPPORT_SWAP = 16, MF_DISABLE_ALLOWED = 32, MF_SUPPORT_EDIT = 64, MF_INACTIVE = 128
}
 Bitwise coded flags used to find out supported features. More...
 
enum  ChangeFlags { CF_SET_INSERTED = 0x5af60, CF_SET_REMOVED, CF_SET_NAME_CHANGED, CF_SET_ENABLE_CHANGED }
 Possible changes of the manager's data model. More...
 
typedef QSet< QByteArray > TypeIds
 
- Public Types inherited from iprm::ISelectionParam
enum  ChangeFlags { CF_SELECTION_CHANGED = 0x67364be }
 Data model change notification flags. More...
 
enum  { NO_SELECTION = -1 }
 
- Public Types inherited from istd::IChangeable
enum  ChangeFlags {
  CF_ACF_INTERNAL = 0, CF_ALL_DATA, CF_ANY, CF_DESTROYING,
  CF_DELEGATED, CF_NO_UNDO
}
 Data model change notification flags. More...
 
enum  SupportedOperations {
  SO_NONE = 0, SO_OBSERVE = 1 << 0, SO_COPY = 1 << 1, SO_CLONE = 1 << 2,
  SO_COMPARE = 1 << 3, SO_RESET = 1 << 4
}
 Flags for supported operations. More...
 
enum  CompatibilityMode { CM_STRICT, CM_WITHOUT_REFS, CM_WITH_REFS, CM_CONVERT }
 Control how relationship betweeen objects are interpreted. More...
 

Public Member Functions

virtual int GetIndexOperationFlags (int index=-1) const =0
 Get operation control flags of some paramter set or whole manager. More...
 
virtual int GetParamsSetsCount () const =0
 Get number of managed set. More...
 
virtual const IOptionsListGetParamsTypeConstraints () const =0
 Get selection contraints describing each supported type. More...
 
virtual int InsertParamsSet (int typeIndex=-1, int index=-1)=0
 Insert new parameters set at selected position. More...
 
virtual bool RemoveParamsSet (int index)=0
 Remove parameters set at selected position. More...
 
virtual bool SwapParamsSet (int index1, int index2)=0
 Swap two parameter sets. More...
 
virtual IParamsSetGetParamsSet (int index) const =0
 Get selected parameter set. More...
 
virtual IParamsSetCreateParameterSet (int typeIndex=-1, int index=-1) const =0
 
virtual QString GetParamsSetName (int index) const =0
 Get name of specified parameter set. More...
 
virtual bool SetParamsSetName (int index, const QString &name)=0
 Set name of specified parameter set. More...
 
virtual QString GetParamsSetDescription (int index) const =0
 Get the description of the specified parameter set. More...
 
virtual void SetParamsSetDescription (int index, const QString &description)=0
 Set the description of the specified parameter set. More...
 
- Public Member Functions inherited from iprm::ISelectionParam
virtual const IOptionsListGetSelectionConstraints () const =0
 Get constraints of this parameter. More...
 
virtual int GetSelectedOptionIndex () const =0
 Get selected index. More...
 
virtual bool SetSelectedOptionIndex (int index)=0
 Set index of selected option. More...
 
virtual ISelectionParamGetSubselection (int index) const =0
 Get subselection for specified option. More...
 
- Public Member Functions inherited from iser::ISerializable
virtual bool Serialize (IArchive &archive)=0
 Load or store state of this object as a archive stream. More...
 
virtual quint32 GetMinimalVersion (int versionId) const
 Get minimal needed version to correct storing of this data. More...
 
- Public Member Functions inherited from istd::IChangeable
virtual int GetSupportedOperations () const
 Get set of flags for supported operations. More...
 
virtual bool CopyFrom (const IChangeable &object, CompatibilityMode mode=CM_WITHOUT_REFS)
 Copy this object from another one. More...
 
virtual bool IsEqual (const IChangeable &object) const
 Compare this object with another object. More...
 
virtual IChangeableCloneMe (CompatibilityMode mode=CM_WITHOUT_REFS) const
 Make a copy of this object. More...
 
virtual bool ResetData (CompatibilityMode mode=CM_WITHOUT_REFS)
 Reset data to its default state. More...
 
virtual void BeginChanges (const ChangeSet &changeSet)
 Starts the change transaction. More...
 
virtual void EndChanges (const ChangeSet &changeSet)
 Ends the change transaction. More...
 
virtual void BeginChangeGroup (const ChangeSet &changeSet)
 Starts group of changes. More...
 
virtual void EndChangeGroup (const ChangeSet &changeSet)
 Ends group of changes. More...
 
- Public Member Functions inherited from istd::IPolymorphic
virtual ~IPolymorphic ()
 

Additional Inherited Members

- Static Public Member Functions inherited from istd::IChangeable
static const ChangeSetGetNoChanges ()
 Get empty set of changes. More...
 
static const ChangeSetGetAnyChange ()
 Get anonymous change set. More...
 
static const ChangeSetGetAllChanges ()
 Get anonymous change set. More...
 
static const ChangeSetGetDelegatedChanges ()
 Get delegated change set. More...
 
- Protected Member Functions inherited from istd::IChangeable
virtual void OnBeginChanges ()
 Callback function for begin change event. More...
 
virtual void OnEndChanges (const ChangeSet &changeSet)
 Callback function for end change event. More...
 

Detailed Description

Manager of parameters set.

Definition at line 24 of file IParamsManager.h.

Member Typedef Documentation

typedef QSet<QByteArray> iprm::IParamsManager::TypeIds

Definition at line 27 of file IParamsManager.h.

Member Enumeration Documentation

Possible changes of the manager's data model.

Enumerator
CF_SET_INSERTED 
CF_SET_REMOVED 
CF_SET_NAME_CHANGED 
CF_SET_ENABLE_CHANGED 

Definition at line 77 of file IParamsManager.h.

Bitwise coded flags used to find out supported features.

Enumerator
MF_COUNT_FIXED 

Active if number of parameters is fixed.

MF_SUPPORT_RENAME 

Active if rename of parameters is supported.

MF_SUPPORT_INSERT 

Active if insert of parameters is possible.

MF_SUPPORT_DELETE 

Active if delete of parameters is possible.

MF_SUPPORT_SWAP 

Active if swap of parameters with the other one is possible.

MF_DISABLE_ALLOWED 

Active if it is possible to get the disabled option.

MF_SUPPORT_EDIT 

Active if it is possible to edit parameter values.

MF_INACTIVE 

Option is inactive (i.e.

cannot be activated or selected)

Definition at line 31 of file IParamsManager.h.

Member Function Documentation

virtual IParamsSet* iprm::IParamsManager::CreateParameterSet ( int  typeIndex = -1,
int  index = -1 
) const
pure virtual
Parameters
typeIndexIndex of parameter type. This index is context specified and is used to indicate type of parameters should be created. If equals negative value, the type will be automatically selected.
indexIf index is not negative, the parameter set data at the given position will be copied to the created instance.
Note
The caller is responsible for the memory mangement of the created parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual int iprm::IParamsManager::GetIndexOperationFlags ( int  index = -1) const
pure virtual

Get operation control flags of some paramter set or whole manager.

See Also
ManagerFlags.
Parameters
indexindex addressing position in parameter set list. For negative value general flags are returned. For example if you want to check if there is any renameable element you should call it with negative index value. To check if first element can be renamed call it with index value 0. To check if you can insert at the last position please use index value equal to current number of parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual IParamsSet* iprm::IParamsManager::GetParamsSet ( int  index) const
pure virtual

Get selected parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual QString iprm::IParamsManager::GetParamsSetDescription ( int  index) const
pure virtual

Get the description of the specified parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual QString iprm::IParamsManager::GetParamsSetName ( int  index) const
pure virtual

Get name of specified parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual int iprm::IParamsManager::GetParamsSetsCount ( ) const
pure virtual

Get number of managed set.

Implemented in iprm::CParamsManagerCompBase.

virtual const IOptionsList* iprm::IParamsManager::GetParamsTypeConstraints ( ) const
pure virtual

Get selection contraints describing each supported type.

Returns
NULL, if only one annonymed type is supported.

Implemented in iprm::CParamsManagerComp, and iprm::CMultiParamsManagerComp.

virtual int iprm::IParamsManager::InsertParamsSet ( int  typeIndex = -1,
int  index = -1 
)
pure virtual

Insert new parameters set at selected position.

Parameters
typeIndexIndex of parameter type. This index is context specified and is used to indicate type of parameters should be added. If equals negative value the type will be automatically selected.
indexPosition in list of parameters or negative value to use default position.
Returns
Position of inserted new entry or negative value if no insert was possible. For specified index positions (positive index value) it will return the same index or negative value.

Implemented in iprm::CParamsManagerCompBase.

virtual bool iprm::IParamsManager::RemoveParamsSet ( int  index)
pure virtual

Remove parameters set at selected position.

Implemented in iprm::CParamsManagerCompBase.

virtual void iprm::IParamsManager::SetParamsSetDescription ( int  index,
const QString &  description 
)
pure virtual

Set the description of the specified parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual bool iprm::IParamsManager::SetParamsSetName ( int  index,
const QString &  name 
)
pure virtual

Set name of specified parameter set.

Implemented in iprm::CParamsManagerCompBase.

virtual bool iprm::IParamsManager::SwapParamsSet ( int  index1,
int  index2 
)
pure virtual

Swap two parameter sets.

Implemented in iprm::CParamsManagerCompBase.


The documentation for this class was generated from the following file:

© 2007-2017 Witold Gantzke and Kirill Lepskiy