Made to Order Software Corporation Logo

libsswf: sswf::ActionLabel Class Reference

Create a label in an action script. More...

#include <libsswf.h>

Inheritance diagram for sswf::ActionLabel:

:Action :MemoryManager :ItemBase :MemBuffer

List of all members.


Public Member Functions

 ActionLabel (TagBase *tag)
 Initialize an ActionLabel.
const char * GetLabel (void) const
 Get the name of this label.
void SetLabel (const char *label)
 Set the name of an ActionLabel.

Private Member Functions

virtual ActionDuplicate (void) const
 Create a duplicate of the label.

Private Attributes

char * f_label

Detailed Description

An ActionLabel is an SSWF addition which is not saved in the SWF movie. It is used to indicate where a BranchAction can branch.

Constructor & Destructor Documentation

ActionLabel::ActionLabel ( TagBase tag  ) 

An action label is set to "no name" by default. You are expected to call SetLabel() once initialized.

Parameters:
[in] tag The tag including this action

References f_label.

Referenced by Duplicate().


Member Function Documentation

Action * ActionLabel::Duplicate ( void   )  const [private, virtual]

This function creates a new label action and copies the label of 'this' action.

Returns:
The pointer to the new ActionLabel

Reimplemented from sswf::Action.

References ActionLabel(), f_label, SetLabel(), and sswf::Action::Tag().

ActionLabel::GetLabel ( void   )  const [inline]

This function retrieves the name of this label. It is used to search all the labels in an array of actions.

Returns:
The name of this label

References f_label.

Referenced by sswf::Action::FindLabel(), and sswf::ActionBranch::Parse2ndPass().

void ActionLabel::SetLabel ( const char *  label  ) 

This function defines the name of an ActionLabel. The name can be any valid string. It should not be empty.

Parameters:
[in] label The new label name

References f_label, sswf::MemoryManager::MemFree(), and sswf::MemoryManager::StrDup().

Referenced by Duplicate(), and sswf::Action::FindLabelAtOffset().


Member Data Documentation


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


Generated on Wed Mar 18 15:13:57 2009 for libsswf by  doxygen 1.5.5