VOS::VobjectEvent Class Reference
[libvos]
#include <vos/vos/vobjectevent.hh>
Inheritance diagram for VOS::VobjectEvent:

Detailed Description
This class describes an event changing the state of a Vobject.This event has either been requested to happen or has already happened, depending respectively on whether it is supplied as part of an access control callback or a listener notification callback.
- Note:
- A VobjectEvent is a reference counted object. This means that you may keep a reference to an event which has been passed to you if you increment its count with acquire() and/or use vRef<>.
Definition at line 54 of file vobjectevent.hh.
Public Types
- TypeInsert
- TypeRemove
- ParentInsert
- ParentRemove
- ChildInsert
- ChildReplace
- ChildRemove
- ReadChild
- ReadParent
- ReadType
- ChildrenListen
- ParentListen
- TypeListen
- ReadACL
- AddToACL
- RemoveFromACL
- DeleteACL
- SetDefaultPolicy
- enum EventType {
TypeInsert, TypeRemove, ParentInsert, ParentRemove,
ChildInsert, ChildReplace, ChildRemove, ReadChild,
ReadParent, ReadType, ChildrenListen, ParentListen,
TypeListen, ReadACL, AddToACL, RemoveFromACL,
DeleteACL, SetDefaultPolicy
}
Public Member Functions
- VobjectEvent (EventType et, Vobject *init, Vobject &fromobj, int pos, const std::string &contextname, Vobject &childobj)
- VobjectEvent (EventType et, Vobject *init, Vobject &fromobj, int pos, const std::string &contextname, Vobject &newobj, Vobject &oldobj)
- VobjectEvent (EventType et, Vobject *init, Vobject &fromobj, const std::string &str)
- VobjectEvent (EventType et, Vobject *requester, Vobject &fromobj)
- VobjectEvent (EventType et, Vobject *requester, Vobject &fromobj, const std::string &acl, Vobject &aclmember)
- virtual ~VobjectEvent ()
- EventType getEvent ()
- VUtil::vRef< Vobject > getInitiator ()
- VUtil::vRef< Vobject > getParent ()
- VUtil::vRef< Vobject > getAffectedObject ()
- VUtil::vRef< Vobject > getChild ()
- VUtil::vRef< Vobject > getACLMember ()
- VUtil::vRef< Vobject > getNewChild ()
- VUtil::vRef< Vobject > getOldChild ()
- int getPosition ()
- const std::string & getContextualName ()
- const std::string & getNewType ()
- const std::string & getType ()
- const std::string & getOldType ()
- const std::string & getAffectedACL ()
- void deliverTo (ChildChangeListener *ccl)
- void deliverTo (TypeChangeListener *ccl)
- void deliverTo (ParentChangeListener *ccl)
Member Enumeration Documentation
- Enumerator:
Definition at line 57 of file vobjectevent.hh.
Constructor & Destructor Documentation
| VOS::VobjectEvent::VobjectEvent | ( | EventType | et, | |
| Vobject * | init, | |||
| Vobject & | fromobj, | |||
| int | pos, | |||
| const std::string & | contextname, | |||
| Vobject & | childobj | |||
| ) |
Construct a ReadChild, ReadParent, ChildInserted, ChildRemoved, ParentInserted or ParentRemoved event.
- Parameters:
-
et The type of event that occured init The object which caused this event to occur fromobj The parent object involved pos The position of the child object in question contextname The contextual name of the child object in question childobj The child object involved
| VOS::VobjectEvent::VobjectEvent | ( | EventType | et, | |
| Vobject * | init, | |||
| Vobject & | fromobj, | |||
| int | pos, | |||
| const std::string & | contextname, | |||
| Vobject & | newobj, | |||
| Vobject & | oldobj | |||
| ) |
Construct a ChildReplaced event.
- Parameters:
-
et The type of event that occured init The object which caused this event to occur fromobj The parent object pos The position of the child object in question contextname The contextual name of the child object in question newobj The new child at this position oldobj The old child at this position
| VOS::VobjectEvent::VobjectEvent | ( | EventType | et, | |
| Vobject * | init, | |||
| Vobject & | fromobj, | |||
| const std::string & | str | |||
| ) |
Construct a ReadType, TypeInserted, TypeRemoved or RemoveACL event.
- Parameters:
-
et The type of event that occured init The object which caused this event to occur fromobj The parent object of this child change event str The newly added type string for Type events, or the ACL for RemoveACL event
Construct a ChildrenListen, ParentListen TypeListen or ReadACL event.
- Parameters:
-
et The type of event that occured requester The object which wants to start listening or do the read fromobj The object that will be listened to or read from
| VOS::VobjectEvent::VobjectEvent | ( | EventType | et, | |
| Vobject * | requester, | |||
| Vobject & | fromobj, | |||
| const std::string & | acl, | |||
| Vobject & | aclmember | |||
| ) |
Construct an AddToACL or RemoveFromACL event.
- Parameters:
-
et The type of event that occured requester The object which wants to make the change fromobj the object on which the security is changing acl the access control list to change aclmember The identity or group that will be added or removed from the ACL
| virtual VOS::VobjectEvent::~VobjectEvent | ( | ) | [virtual] |
Member Function Documentation
| void VOS::VobjectEvent::deliverTo | ( | ParentChangeListener * | ccl | ) |
| void VOS::VobjectEvent::deliverTo | ( | TypeChangeListener * | ccl | ) |
| void VOS::VobjectEvent::deliverTo | ( | ChildChangeListener * | ccl | ) |
| VUtil::vRef<Vobject> VOS::VobjectEvent::getACLMember | ( | ) | [inline] |
- Returns:
- The identity or group to be added or removed on a AddToACL or RemoveFromACL event.
Definition at line 154 of file vobjectevent.hh.
| const std::string& VOS::VobjectEvent::getAffectedACL | ( | ) | [inline] |
| VUtil::vRef<Vobject> VOS::VobjectEvent::getAffectedObject | ( | ) | [inline] |
- Returns:
- The Vobject which is changing state. Always a valid object.
Definition at line 144 of file vobjectevent.hh.
| VUtil::vRef<Vobject> VOS::VobjectEvent::getChild | ( | ) | [inline] |
- Returns:
- The child Vobject which was affected on a ParentInsert or ParentRemove event, or the requested object to read on a ReadChild event. Will be NULL for TypeInsert, TypeRemove and all Listen events.
Definition at line 150 of file vobjectevent.hh.
| const std::string& VOS::VobjectEvent::getContextualName | ( | ) | [inline] |
| EventType VOS::VobjectEvent::getEvent | ( | ) | [inline] |
| VUtil::vRef<Vobject> VOS::VobjectEvent::getInitiator | ( | ) | [inline] |
- Returns:
- The object which requested or initiated this event. May be null. For access control checks, this is the object which is requesting access.
Definition at line 135 of file vobjectevent.hh.
| VUtil::vRef<Vobject> VOS::VobjectEvent::getNewChild | ( | ) | [inline] |
- Returns:
- The child Vobject which was newly added on a ChildInsert or ChildReplace event. Will be NULL for ChildRemove, TypeInsert, TypeRemove and all Read and Listen events.
Definition at line 160 of file vobjectevent.hh.
| const std::string& VOS::VobjectEvent::getNewType | ( | ) | [inline] |
- Returns:
- The added or removed type for type change events.
Definition at line 175 of file vobjectevent.hh.
| VUtil::vRef<Vobject> VOS::VobjectEvent::getOldChild | ( | ) | [inline] |
- Returns:
- The previous Vobject occupying this position. Only valid for ChildRemove and ChildReplace events, NULL otherwise.
Definition at line 165 of file vobjectevent.hh.
| const std::string& VOS::VobjectEvent::getOldType | ( | ) | [inline] |
- Returns:
- The added or removed type for type change events.
Definition at line 179 of file vobjectevent.hh.
| VUtil::vRef<Vobject> VOS::VobjectEvent::getParent | ( | ) | [inline] |
- Returns:
- The parent Vobject being changed. Always a vaild object.
Definition at line 139 of file vobjectevent.hh.
| int VOS::VobjectEvent::getPosition | ( | ) | [inline] |
- Returns:
- The absolute position of the child Vobject in parent, or -1 if this is a TypeInserted or TypeRemoved event.
Definition at line 169 of file vobjectevent.hh.
| const std::string& VOS::VobjectEvent::getType | ( | ) | [inline] |
- Returns:
- The added or removed type for type change events.
Definition at line 177 of file vobjectevent.hh.
The documentation for this class was generated from the following file:
- /home/tetron/hack/vos/libs/vos/vos/vobjectevent.hh