Gnash  0.8.10
Public Types | Public Member Functions
gnash::PropFlags Class Reference

Flags defining the level of protection of a member. More...

#include <PropFlags.h>

List of all members.

Public Types

enum  Flags {
  dontEnum = 1 << 0, dontDelete = 1 << 1, readOnly = 1 << 2, onlySWF6Up = 1 << 7,
  ignoreSWF6 = 1 << 8, onlySWF7Up = 1 << 10, onlySWF8Up = 1 << 12, onlySWF9Up = 1 << 13
}
 Actual flags. More...

Public Member Functions

 PropFlags ()
 Default constructor.
 PropFlags (const bool read_only, const bool dont_delete, const bool dont_enum)
 Constructor.
 PropFlags (boost::uint16_t flags)
 Constructor, from numerical value.
bool operator== (const PropFlags &o) const
bool operator!= (const PropFlags &o) const
template<Flags f>
bool test () const
bool get_visible (int swfVersion) const
 Get version-based visibility.
void clear_visible (int swfVersion)
boost::uint16_t get_flags () const
 accessor to the numerical flags value
bool set_flags (boost::uint16_t setTrue, boost::uint16_t setFalse=0)

Detailed Description

Flags defining the level of protection of a member.


Member Enumeration Documentation

Actual flags.

Enumerator:
dontEnum 

Protect from enumeration.

dontDelete 

Protect from deletion.

readOnly 

Protect from assigning a value.

onlySWF6Up 

Only visible by VM initialized for version 6 or higher.

ignoreSWF6 

Ignore in SWF6-initialized VM.

onlySWF7Up 

Only visible by VM initialized for version 7 or higher.

onlySWF8Up 

Only visible by VM initialized for version 8 or higher.

onlySWF9Up 

Only visible by VM initialized for version 9 or higher.


Constructor & Destructor Documentation

gnash::PropFlags::PropFlags ( ) [inline]

Default constructor.

gnash::PropFlags::PropFlags ( const bool  read_only,
const bool  dont_delete,
const bool  dont_enum 
) [inline]

Constructor.

gnash::PropFlags::PropFlags ( boost::uint16_t  flags) [inline]

Constructor, from numerical value.


Member Function Documentation

void gnash::PropFlags::clear_visible ( int  swfVersion) [inline]
boost::uint16_t gnash::PropFlags::get_flags ( ) const [inline]

accessor to the numerical flags value

bool gnash::PropFlags::get_visible ( int  swfVersion) const [inline]

Get version-based visibility.

bool gnash::PropFlags::operator!= ( const PropFlags o) const [inline]

References gnash::key::o.

bool gnash::PropFlags::operator== ( const PropFlags o) const [inline]
bool gnash::PropFlags::set_flags ( boost::uint16_t  setTrue,
boost::uint16_t  setFalse = 0 
) [inline]

set the numerical flags value (return the new value ) If unlocked is false, you cannot un-protect from over-write, you cannot un-protect from deletion and you cannot un-hide from the for..in loop construct

Parameters:
setTruethe set of flags to set
setFalsethe set of flags to clear
Returns:
true on success, false on failure (is protected)

Referenced by gnash::PropertyList::setFlags(), and gnash::PropertyList::setFlagsAll().

template<Flags f>
bool gnash::PropFlags::test ( ) const [inline]

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