LAttachment is a PowerPlant class that is used for forming relataionships between objects. An Attachment is usually an object that modifies the runtime behavior of another object.
Methods :
The methods in this class are:
Data Members:
The data members in this class are:
Operation:
The concept of an Attachment is a powerful underlying concept of PowerPlant's inner workings. For a detailed discussion on this topic, refer to The PowerPlant Book.
Source files:
See also:
Purpose:
The constructors create the object and initialize the data members to the passed-in values.
Access:
Prototype:
LAttachment( MessageT inMessage,
Boolean inExecuteHost);
LAttachment( LStream *inStream );Parameters:
The parameters for the constructors are:
|
||
|
||
|
Purpose:
The destructor destroys the object, removing itself from any Attachments.
Access:
Prototype:
virtual ~LAttachment();Parameters:
Purpose:
If the message passed to this method is the message for which the Attachment is designed, this method calls ExecuteSelf().
Access:
Prototype:
virtual Boolean Execute( MessageT inMessage,Parameters:
void *ioParam);
This method has the following parameters:
Return:
A Boolean with the value of mExecuteHost. The PowerPlant framework uses this value to decide whether the
host object should also perform the task in question.
Remarks:
You do not typically need to override this function.
Purpose:
This method performs the attachment task. You typically want to override this method in your class that inherits from LAttachment.
Access:
Prototype:
void ExecuteSelf(MessageT inMessage,Parameters:
void* ioParam );
This method has the following parameters:
Return:
Remarks:
To get an idea of how to implement this method in your class override, look at classes like LPaintAttachment to see how it is implemented.
Purpose:
This method is an accessor for the value of mExecuteHost.
Access:
Prototype:
Boolean GetExecuteHost();Parameters:
Return:
A Boolean indicating the value of mExecuteHost.
Purpose:
This method is an accessor for the value of mMessage.
Access:
Prototype:
MessageT GetMessage();Parameters:
Return:
A MessageT indicating the value of mMessage.
Purpose:
This method is an accessor for the value of mOwnerHost.
Access:
Prototype:
LAttachable* GetOwnerHost();Parameters:
Return:
An LAttachable pointer indicating the value of mOwnerHost.
Purpose:
Sets the value of mExecuteHost, that specifies whether the host action should execute after executing all Attachments.
Access:
Prototype:
void SetExecuteHost( Boolean inExecuteHost );Parameters:
This method takes a Boolean to assign to mExecuteHost.
Return:
Purpose:
Sets the value of mMessage.
Access:
Prototype:
void SetMessage( MessageT inMessage );Parameters:
A MessageT to assign to mMessage.
Return:
Purpose:
Sets the value of mOwnerHost.
Access:
Prototype:
void SetOwnerHost( LAttachable *inHost );Parameters:
A pointer to an LAttachable to assign to mOwnerHost.
Return:
Purpose:
This data member points to the host attachable object.
Access:
Prototype:
LAttachable *mOwnerHost;
Purpose:
This data member contains the message value to which the attachable object responds.
Access:
Prototype:
MessageT mMessage;
Purpose:
This data member indicates whether or not to execute the host object action.
Access:
Prototype:
Boolean mExecuteHost;