|
The Vish Visualization Shell 0.3
Vish
|
Given some VObject, this is the accompanying Creator object that may be used to create VObject's on request. More...
#include <ocean/plankton/VCreator.hpp>
Public Member Functions | |
| VAcceptInfoList_t | accept (const RefPtr< VObject > &vobj) const override |
| Implementation of the acception function. | |
| RefPtr< VObject > | create (const VCreatorBase::CreationInfo &name, const Intercube &CreationContext, const RefPtr< VCreationPreferences > &AdditionalPreferences) const override |
| Actually create the associated VObject on request from the base class. | |
| string | createChildname (const string &parent_name) const override |
| Implementation of the child name creation functionality. | |
| VCreator (const VCreatorProperties &CreatorProperties, int quality, const RefPtr< VCreationPreferences > &prop=nullptr, const char *const CreatorReleaseIdentifier=VISH_CREATOR_RELEASE_IDENTIFIER) | |
| Construct a creator object with full properties specified. | |
| template<unsigned ID> | |
| VCreator (const VCreatorProperty< ID > &CreatorProperties, int quality, const RefPtr< VCreationPreferences > &prop=nullptr, const char *const ReleaseIdentifier=VISH_CREATOR_RELEASE_IDENTIFIER) | |
| Construct a creator object with full properties specified. | |
Related Symbols | |
(Note that these are not member symbols.) | |
| template<unsigned ID1, unsigned ID2> | |
| VCreatorProperty< ID1+ID2 > | operator+ (const VCreatorProperty< ID1 > &l, const VCreatorProperty< ID2 > &r) |
| Merge two properties via the + operator. | |
| template<unsigned ID1, unsigned ID2> | |
| VCreatorProperty< ID1+ID2 > | operator/ (const VCreatorProperty< ID1 > &l, const VCreatorProperty< ID2 > &r) |
| Merge two properties via the / operator, same as using the + operator (just another syntax). | |
Given some VObject, this is the accompanying Creator object that may be used to create VObject's on request.
The VObject must provide a constructor taking the new object's name and its priority number, which is forwarded from the creator's priority.
VCreator objects come with a property that tells whether the object it might create is suitable as output for a certain, existing VObject. A such, the existing VObject is to be checked for its properties to see if this VCreator is suitable for bearing a child object. This check is done through the virtual accept() member function. A specific VCreator may always overload this function to implement any operation.
The default VCreator utilizes a list of properties managed through the AcceptListIterator<> template. This one allows to specify a list of types. If any of these types is managed in the existing VObject, then the accept() function will return true. It is an OR of all properties.
The AcceptListIterator may also be used to implement operations on user defined types. For this, it needs to be specialized for a certain type and implement an accept() function such as in this following code snippet:
The accept() function may of course be arbitrarily complex. By default, there are accept list iterators implemented for native types (which are provided via output parameters of VObjects), and interfaces, that are attached to VObjects.
|
inline |
Construct a creator object with full properties specified.
| CreatorProperties | The properties of this creator, it is recommendable to make use of namespace Panthalassia or ProtoOcean. |
| quality | The object's matureness, according to ObjectQuality |
References Wizt::VCreatorPropertyBase::keyname(), Wizt::VCreatorBase(), and Wizt::Vprintf().
|
inline |
Construct a creator object with full properties specified.
| CreatorProperties | The properties of this creator, it is recommendable to make use of namespace Panthalassia or ProtoOcean. |
| quality | The object's matureness, according to ObjectQuality |
Allows to create objects via Panthalassia syntax:
References Wizt::getProperties(), Wizt::VCreatorBase(), and Wizt::Vprintf().
|
inlineoverride |
Implementation of the acception function.
Calls the static accept() function of the DerivedVObject.
|
inlineoverride |
Actually create the associated VObject on request from the base class.
| CreationContext | An Intercube that allows specifying additional parameters for the circumstances of creation. It is passed to the VActionNotifier::VObjectCreation() call. |
References Wizt::VActionNotifier::VObjectCreation(), and Wizt::Vprintf().
|
inlineoverride |
Implementation of the child name creation functionality.
By default, calls a static member function of the derived object on which this VCreator is instantiated.