Usd Notice Framework
0.7.0
|
Convenient RAII object to consolidate and filter notices derived from UnfNotice::StageNotice within a specific scope. More...
#include <transaction.h>
Public Member Functions | |
UNF_API | NoticeTransaction (const BrokerPtr &, CapturePredicate predicate=CapturePredicate::Default()) |
Create transaction from a Broker. More... | |
UNF_API | NoticeTransaction (const BrokerPtr &, const CapturePredicateFunc &) |
Create transaction from a Broker with a capture predicate function. More... | |
UNF_API | NoticeTransaction (const PXR_NS::UsdStageRefPtr &, CapturePredicate predicate=CapturePredicate::Default()) |
Create transaction from a UsdStage. More... | |
UNF_API | NoticeTransaction (const PXR_NS::UsdStageRefPtr &, const CapturePredicateFunc &) |
Create transaction from a UsdStage with a capture predicate function. More... | |
virtual UNF_API | ~NoticeTransaction () |
Delete object and end transaction. | |
UNF_API | NoticeTransaction (const NoticeTransaction &)=delete |
Remove default copy constructor. | |
UNF_API NoticeTransaction & | operator= (const NoticeTransaction &)=delete |
Remove default assignment operator. | |
UNF_API BrokerPtr | GetBroker () |
Return associated Broker instance. | |
Convenient RAII object to consolidate and filter notices derived from UnfNotice::StageNotice within a specific scope.
UNF_API unf::NoticeTransaction::NoticeTransaction | ( | const BrokerPtr & | , |
CapturePredicate | predicate = CapturePredicate::Default() |
||
) |
Create transaction from a Broker.
Notices derived from UnfNotice::StageNotice will be held during the transaction and emitted at the end.
By default, all UnfNotice::StageNotice notices will be captured during the entire scope of the transaction. A CapturePredicate can be passed to influence which notices are captured. Notices that are not captured will not be emitted.
UNF_API unf::NoticeTransaction::NoticeTransaction | ( | const BrokerPtr & | , |
const CapturePredicateFunc & | |||
) |
Create transaction from a Broker with a capture predicate function.
The following example will filter out all 'Foo' notices emitted during the transaction.
UNF_API unf::NoticeTransaction::NoticeTransaction | ( | const PXR_NS::UsdStageRefPtr & | , |
CapturePredicate | predicate = CapturePredicate::Default() |
||
) |
Create transaction from a UsdStage.
Convenient constructor to encapsulate the creation of the broker.
UNF_API unf::NoticeTransaction::NoticeTransaction | ( | const PXR_NS::UsdStageRefPtr & | , |
const CapturePredicateFunc & | |||
) |
Create transaction from a UsdStage with a capture predicate function.
Convenient constructor to encapsulate the creation of the broker.