HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PDG_Event Class Reference

#include <PDG_Event.h>

Public Member Functions

 PDG_Event ()
 Constructs a default initialized null event. More...
 
 PDG_Event (PDG_EventType type, bool can_consolidate, const UT_StringHolder &service_name=UT_StringHolder::theEmptyString, const UT_StringHolder &service_client_name=UT_StringHolder::theEmptyString)
 
 PDG_Event (PDG_EventType type, bool can_consolidate, PDG_GraphContext *context, const PDG_Node *node=nullptr, const PDG_Node *node2=nullptr, PDG_WorkItemID work_item=PDG_WorkItem::theInvalidId, PDG_WorkItemID dependency=PDG_WorkItem::theInvalidId, PDG_WorkItemState current_state=PDG_WorkItemState::eUndefined, PDG_WorkItemState last_state=PDG_WorkItemState::eUndefined)
 Constructs an event for a specific graph context. More...
 
PDG_EventType type () const
 
bool canConsolidate () const
 
PDG_GraphContextcontext () const
 
PDG_Nodenode () const
 
PDG_Nodenode2 () const
 
PDG_Schedulerscheduler () const
 
PDG_WorkItemID workItemId () const
 
PDG_WorkItemID dependencyId () const
 
PDG_WorkItemState currentState () const
 
PDG_WorkItemState lastState () const
 
const UT_StringHoldermessage () const
 
const UT_StringHolderattrName () const
 
const UT_StringHolderoldName () const
 
const UT_StringHoldernewName () const
 
const UT_StringHolderserviceName () const
 
const UT_StringHolderserviceClientName () const
 
const PDG_WorkItemIDArrayworkItemArray () const
 
PDG_NodeID nodeId () const
 
PDG_NodeID node2Id () const
 
const UT_StringHolderschedulerName () const
 
SYS_HashType hash () const
 
bool operator== (const PDG_Event &other) const
 
UT_StringHolder toString () const
 
void consolidate (const PDG_Event &other)
 

Static Public Member Functions

static PDG_Event NodeCreate (PDG_GraphContext *context, const PDG_Node *node)
 Constructs an event for node creation [node]. More...
 
static PDG_Event NodeRemove (PDG_GraphContext *context, const PDG_Node *node)
 Constructs an event for node deletion [node]. More...
 
static PDG_Event NodeRename (PDG_GraphContext *context, const PDG_Node *node, const UT_StringHolder &old_name, const UT_StringHolder &new_name)
 
static PDG_Event NodeConnect (PDG_GraphContext *context, const PDG_Node *input, const PDG_Node *output)
 Constructs an event for two node being connected [node1, node2]. More...
 
static PDG_Event NodeDisconnect (PDG_GraphContext *context, const PDG_Node *input, const PDG_Node *output)
 Constructs an event for two node being disconnected [node1, node2]. More...
 
static PDG_Event NodeFirstCook (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event NodeGenerated (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event NodeCooked (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event NodeClear (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event NodeProgressUpdate (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event DirtyStart (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event DirtyStop (PDG_GraphContext *context, const PDG_Node *node)
 
static PDG_Event DirtyAll (PDG_GraphContext *context)
 
static PDG_Event CookError (PDG_GraphContext *context, const PDG_Node *node, const UT_StringHolder &message)
 
static PDG_Event CookError (PDG_GraphContext *context, const PDG_Scheduler *scheduler, const UT_StringHolder &message)
 
static PDG_Event CookWarning (PDG_GraphContext *context, const PDG_Node *node, const UT_StringHolder &message)
 
static PDG_Event CookWarning (PDG_GraphContext *context, const PDG_Scheduler *scheduler, const UT_StringHolder &message)
 
static PDG_Event CookStart (PDG_GraphContext *context, const PDG_Node *node=nullptr)
 Creates an event that indicates that cooking has started [?node]. More...
 
static PDG_Event CookComplete (PDG_GraphContext *context, const PDG_Node *node=nullptr)
 Creates an event that indicates that cooking has finished [?node]. More...
 
static PDG_Event WorkItemAddDep (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, PDG_WorkItemID dependency)
 
static PDG_Event WorkItemRemoveDep (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, PDG_WorkItemID depdendency)
 
static PDG_Event WorkItemCookPercentUpdate (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item)
 
static PDG_Event WorkItemStateChange (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, PDG_WorkItemState old_state, PDG_WorkItemState new_state)
 
static PDG_Event WorkItemAdd (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item)
 
static PDG_Event WorkItemAddList (PDG_GraphContext *context, const PDG_Node *node, const PDG_WorkItemIDArray &work_items)
 
static PDG_Event WorkItemRemove (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, PDG_WorkItemState state)
 
static PDG_Event WorkItemRemoveList (PDG_GraphContext *context, const PDG_Node *node, const PDG_WorkItemIDArray &work_items)
 
static PDG_Event WorkItemSelect (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item)
 
static PDG_Event WorkItemMergeData (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item)
 
static PDG_Event WorkItemOutputFiles (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item)
 
static PDG_Event WorkItemSetAttrib (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, PDG_AttributeType attr_type, const UT_StringHolder &attr_name)
 
static PDG_Event WorkItemSetIntAttrib (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, const UT_StringHolder &attr_name)
 
static PDG_Event WorkItemSetFloatAttrib (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, const UT_StringHolder &attr_name)
 
static PDG_Event WorkItemSetStringAttrib (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, const UT_StringHolder &attr_name)
 
static PDG_Event WorkItemPriority (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item)
 
static PDG_Event WorkItemBatchInitialized (PDG_GraphContext *context, const PDG_Node *node, PDG_WorkItemID work_item, const PDG_WorkItemIDArray &work_items)
 
static PDG_Event SchedulerAdded (PDG_GraphContext *context, const PDG_Scheduler *scheduler)
 Constructs an event for scheduler creation [scheduler]. More...
 
static PDG_Event SchedulerRemoved (PDG_GraphContext *context, const PDG_Scheduler *scheduler)
 Constructs an event for scheduler removal [scheduler]. More...
 
static PDG_Event SetScheduler (PDG_GraphContext *context, const PDG_Node *node, const PDG_Scheduler *scheduler)
 
static PDG_Event ServiceManagerAll ()
 Constructs an event that indicates services have been modified[]. More...
 
static PDG_Event ServiceStartBegin (const UT_StringHolder &service_name)
 
static PDG_Event ServiceStartEnd (const UT_StringHolder &service_name)
 
static PDG_Event ServiceClientStarted (const UT_StringHolder &service_name, const UT_StringHolder &client_name)
 
static PDG_Event ServiceClientChanged (const UT_StringHolder &service_name, const UT_StringHolder &client_name)
 
static const char * eventName (PDG_EventType type)
 Returns the string name of an event. More...
 

Static Public Attributes

static PDG_Event theEmptyEvent
 

Detailed Description

Definition at line 31 of file PDG_Event.h.

Constructor & Destructor Documentation

PDG_Event::PDG_Event ( )

Constructs a default initialized null event.

PDG_Event::PDG_Event ( PDG_EventType  type,
bool  can_consolidate,
const UT_StringHolder service_name = UT_StringHolder::theEmptyString,
const UT_StringHolder service_client_name = UT_StringHolder::theEmptyString 
)

Constructs an event for use with services, without a graph context as services are global to the session

PDG_Event::PDG_Event ( PDG_EventType  type,
bool  can_consolidate,
PDG_GraphContext context,
const PDG_Node node = nullptr,
const PDG_Node node2 = nullptr,
PDG_WorkItemID  work_item = PDG_WorkItem::theInvalidId,
PDG_WorkItemID  dependency = PDG_WorkItem::theInvalidId,
PDG_WorkItemState  current_state = PDG_WorkItemState::eUndefined,
PDG_WorkItemState  last_state = PDG_WorkItemState::eUndefined 
)

Constructs an event for a specific graph context.

Member Function Documentation

const UT_StringHolder& PDG_Event::attrName ( ) const
inline

Definition at line 350 of file PDG_Event.h.

bool PDG_Event::canConsolidate ( ) const
inline

Definition at line 328 of file PDG_Event.h.

void PDG_Event::consolidate ( const PDG_Event other)
PDG_GraphContext* PDG_Event::context ( ) const
inline

Definition at line 331 of file PDG_Event.h.

static PDG_Event PDG_Event::CookComplete ( PDG_GraphContext context,
const PDG_Node node = nullptr 
)
static

Creates an event that indicates that cooking has finished [?node].

static PDG_Event PDG_Event::CookError ( PDG_GraphContext context,
const PDG_Node node,
const UT_StringHolder message 
)
static

Constructs an event that indicates an error occured in a node while cooking [node, message]

static PDG_Event PDG_Event::CookError ( PDG_GraphContext context,
const PDG_Scheduler scheduler,
const UT_StringHolder message 
)
static

Constructs an event that indicates an error occured in a scheduler while cooking [node, message]

static PDG_Event PDG_Event::CookStart ( PDG_GraphContext context,
const PDG_Node node = nullptr 
)
static

Creates an event that indicates that cooking has started [?node].

static PDG_Event PDG_Event::CookWarning ( PDG_GraphContext context,
const PDG_Node node,
const UT_StringHolder message 
)
static

Constructs an event that indicates a warning occured in a node while cooking [node, message]

static PDG_Event PDG_Event::CookWarning ( PDG_GraphContext context,
const PDG_Scheduler scheduler,
const UT_StringHolder message 
)
static

Constructs an event that indicates a warningoccured in a scheduler while cooking [node, message]

PDG_WorkItemState PDG_Event::currentState ( ) const
inline

Definition at line 343 of file PDG_Event.h.

PDG_WorkItemID PDG_Event::dependencyId ( ) const
inline

Definition at line 340 of file PDG_Event.h.

static PDG_Event PDG_Event::DirtyAll ( PDG_GraphContext context)
static

Constructs an event that indicates that all work items in the graph are being dirtied []

static PDG_Event PDG_Event::DirtyStart ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node began dirtying work items [node]

static PDG_Event PDG_Event::DirtyStop ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node finished dirtying work items [node]

static const char* PDG_Event::eventName ( PDG_EventType  type)
static

Returns the string name of an event.

SYS_HashType PDG_Event::hash ( ) const
PDG_WorkItemState PDG_Event::lastState ( ) const
inline

Definition at line 345 of file PDG_Event.h.

const UT_StringHolder& PDG_Event::message ( ) const
inline

Definition at line 347 of file PDG_Event.h.

const UT_StringHolder& PDG_Event::newName ( ) const
inline

Definition at line 355 of file PDG_Event.h.

PDG_Node* PDG_Event::node ( ) const
PDG_Node* PDG_Event::node2 ( ) const
PDG_NodeID PDG_Event::node2Id ( ) const
inline

Definition at line 368 of file PDG_Event.h.

static PDG_Event PDG_Event::NodeClear ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node has all of its work items dirtied [node]

static PDG_Event PDG_Event::NodeConnect ( PDG_GraphContext context,
const PDG_Node input,
const PDG_Node output 
)
static

Constructs an event for two node being connected [node1, node2].

static PDG_Event PDG_Event::NodeCooked ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node finished cooking work items [node]

static PDG_Event PDG_Event::NodeCreate ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event for node creation [node].

static PDG_Event PDG_Event::NodeDisconnect ( PDG_GraphContext context,
const PDG_Node input,
const PDG_Node output 
)
static

Constructs an event for two node being disconnected [node1, node2].

static PDG_Event PDG_Event::NodeFirstCook ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node cooked for the first time [node]

static PDG_Event PDG_Event::NodeGenerated ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node finished generating work items [node]

PDG_NodeID PDG_Event::nodeId ( ) const
inline

Definition at line 366 of file PDG_Event.h.

static PDG_Event PDG_Event::NodeProgressUpdate ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event that indicates a node generated new work items, but may still have more to generate in the future [node]

static PDG_Event PDG_Event::NodeRemove ( PDG_GraphContext context,
const PDG_Node node 
)
static

Constructs an event for node deletion [node].

static PDG_Event PDG_Event::NodeRename ( PDG_GraphContext context,
const PDG_Node node,
const UT_StringHolder old_name,
const UT_StringHolder new_name 
)
static

Constructs an event that indicates that a node was renamed [node, oldname, newname]

const UT_StringHolder& PDG_Event::oldName ( ) const
inline

Definition at line 353 of file PDG_Event.h.

bool PDG_Event::operator== ( const PDG_Event other) const
PDG_Scheduler* PDG_Event::scheduler ( ) const
static PDG_Event PDG_Event::SchedulerAdded ( PDG_GraphContext context,
const PDG_Scheduler scheduler 
)
static

Constructs an event for scheduler creation [scheduler].

const UT_StringHolder& PDG_Event::schedulerName ( ) const
inline

Definition at line 370 of file PDG_Event.h.

static PDG_Event PDG_Event::SchedulerRemoved ( PDG_GraphContext context,
const PDG_Scheduler scheduler 
)
static

Constructs an event for scheduler removal [scheduler].

static PDG_Event PDG_Event::ServiceClientChanged ( const UT_StringHolder service_name,
const UT_StringHolder client_name 
)
static

Constructs an event that indicates that a service client has been modified [service, client]

const UT_StringHolder& PDG_Event::serviceClientName ( ) const
inline

Definition at line 360 of file PDG_Event.h.

static PDG_Event PDG_Event::ServiceClientStarted ( const UT_StringHolder service_name,
const UT_StringHolder client_name 
)
static

Constructs an event that indicates that a service client has stopped [service, client]

static PDG_Event PDG_Event::ServiceManagerAll ( )
static

Constructs an event that indicates services have been modified[].

const UT_StringHolder& PDG_Event::serviceName ( ) const
inline

Definition at line 358 of file PDG_Event.h.

static PDG_Event PDG_Event::ServiceStartBegin ( const UT_StringHolder service_name)
static

Constructs an event that indicates that a specific service has started [service]

static PDG_Event PDG_Event::ServiceStartEnd ( const UT_StringHolder service_name)
static

Constructs an event that indicates that a specific service has stopped [service]

static PDG_Event PDG_Event::SetScheduler ( PDG_GraphContext context,
const PDG_Node node,
const PDG_Scheduler scheduler 
)
static

Constructs an event for a scheduler being assigned to a node [node, scheduler]

UT_StringHolder PDG_Event::toString ( ) const
PDG_EventType PDG_Event::type ( ) const
inline

Definition at line 326 of file PDG_Event.h.

static PDG_Event PDG_Event::WorkItemAdd ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item 
)
static

Creates an event that indicates that a work item was added to a node [node, workitem]

static PDG_Event PDG_Event::WorkItemAddDep ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
PDG_WorkItemID  dependency 
)
static

Creates an event that indicates that a dependency was added between two work items [workitem, dependency]

static PDG_Event PDG_Event::WorkItemAddList ( PDG_GraphContext context,
const PDG_Node node,
const PDG_WorkItemIDArray work_items 
)
static

Creates an event that indicates that a list of work items was added to a node [node, workitemArray]

const PDG_WorkItemIDArray& PDG_Event::workItemArray ( ) const
inline

Definition at line 363 of file PDG_Event.h.

static PDG_Event PDG_Event::WorkItemBatchInitialized ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
const PDG_WorkItemIDArray work_items 
)
static

Constructs an event that indicates that a batch work item was initialized [node, workitems]

static PDG_Event PDG_Event::WorkItemCookPercentUpdate ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item 
)
static

Creates an event that indicates a work item's cook progress was updated [node, workitem]

PDG_WorkItemID PDG_Event::workItemId ( ) const
inline

Definition at line 338 of file PDG_Event.h.

static PDG_Event PDG_Event::WorkItemMergeData ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item 
)
static

Constructs an event that indicates a work item's attribute data was updated [node, workitem]

static PDG_Event PDG_Event::WorkItemOutputFiles ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item 
)
static

Constructs an event that indicates a work item's output files were updated [node, workitem]

static PDG_Event PDG_Event::WorkItemPriority ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item 
)
static

Constructs an event that indicates a work item's priority changed [node, workitem]

static PDG_Event PDG_Event::WorkItemRemove ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
PDG_WorkItemState  state 
)
static

Constructs an event that indicates a work item was removed from a node [node, workitem, state]

static PDG_Event PDG_Event::WorkItemRemoveDep ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
PDG_WorkItemID  depdendency 
)
static

Creates an event that indicates that a dependency was removed between two work items [workitem, dependency]

static PDG_Event PDG_Event::WorkItemRemoveList ( PDG_GraphContext context,
const PDG_Node node,
const PDG_WorkItemIDArray work_items 
)
static

Constructs an event that indicates a list of work item was removed from a node [node, workitemArray]

static PDG_Event PDG_Event::WorkItemSelect ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item 
)
static

Constructs an event that indicates a work item was selected in the UI [node, workitem]

static PDG_Event PDG_Event::WorkItemSetAttrib ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
PDG_AttributeType  attr_type,
const UT_StringHolder attr_name 
)
static

Constructs an event that indicates an attribute was changed on a work item [node, workitem, attribname]

static PDG_Event PDG_Event::WorkItemSetFloatAttrib ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
const UT_StringHolder attr_name 
)
static

Constructs an event that indicates a float attribute was changed on a work item [node, workitem, attribname]

static PDG_Event PDG_Event::WorkItemSetIntAttrib ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
const UT_StringHolder attr_name 
)
static

Constructs an event that indicates an integer attribute was changed on a work item [node, workitem, attribname]

static PDG_Event PDG_Event::WorkItemSetStringAttrib ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
const UT_StringHolder attr_name 
)
static

Constructs an event that indicates a string attribute was changed on a work item [node, workitem, attribname]

static PDG_Event PDG_Event::WorkItemStateChange ( PDG_GraphContext context,
const PDG_Node node,
PDG_WorkItemID  work_item,
PDG_WorkItemState  old_state,
PDG_WorkItemState  new_state 
)
static

Creates an event that indicates that a work item changed states [node, oldstate, newstate]

Member Data Documentation

PDG_Event PDG_Event::theEmptyEvent
static

Empty, null-initialized event that can be used when clear constructing event data structures, or passing a default value to an event reference parameter

Definition at line 37 of file PDG_Event.h.


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