![]() |
Open CASCADE Technology Reference Manual 8.0.0
|
Manages Transfer of Transient Objects. Produces also ActorOfTransientProcess (deferred class), IteratorOfTransientProcess (for Results), TransferMapOfTransientProcess (internally used) Normally uses as TransientProcess, which adds some specifics. More...
#include <Transfer_ProcessForTransient.hxx>

Public Member Functions | |
| Transfer_ProcessForTransient (const int nb=10000) | |
| Sets TransferProcess at initial state. Gives an Initial size (indicative) for the Map when known (default is 10000). Sets default trace file as a printer and default trace level (see Message_TraceFile). | |
| Transfer_ProcessForTransient (const occ::handle< Message_Messenger > &printer, const int nb=10000) | |
| Sets TransferProcess at initial state. Gives an Initial size (indicative) for the Map when known (default is 10000). Sets a specified printer. | |
| void | Clear () |
| Resets a TransferProcess as ready for a completely new work. Clears general data (roots) and the Map. | |
| void | Clean () |
| Rebuilds the Map and the roots to really remove Unbound items Because Unbind keeps the entity in place, even if not bound Hence, working by checking new items is meaningless if a formerly unbound item is rebound. | |
| void | Resize (const int nb) |
| Resizes the Map as required (if a new reliable value has been determined). Acts only if <nb> is greater than actual NbMapped. | |
| void | SetActor (const occ::handle< Transfer_ActorOfProcessForTransient > &actor) |
| Defines an Actor, which is used for automatic Transfer If already defined, the new Actor is cumulated (see SetNext from Actor) | |
| occ::handle< Transfer_ActorOfProcessForTransient > | Actor () const |
| Returns the defined Actor. Returns a Null Handle if not set. | |
| occ::handle< Transfer_Binder > | Find (const occ::handle< Standard_Transient > &start) const |
| Returns the Binder which is linked with a starting Object It can either bring a Result (Transfer done) or none (for a pre-binding). If no Binder is linked with <start>, returns a Null Handle Considers a category number, by default 0. | |
| bool | IsBound (const occ::handle< Standard_Transient > &start) const |
| Returns True if a Result (whatever its form) is Bound with a starting Object. I.e., if a Binder with a Result set, is linked with it Considers a category number, by default 0. | |
| bool | IsAlreadyUsed (const occ::handle< Standard_Transient > &start) const |
| Returns True if the result of the transfer of an object is already used in other ones. If it is, Rebind cannot change it. Considers a category number, by default 0. | |
| void | Bind (const occ::handle< Standard_Transient > &start, const occ::handle< Transfer_Binder > &binder) |
| Creates a Link a starting Object with a Binder. This Binder can either bring a Result (effective Binding) or none (it can be set later : pre-binding). Considers a category number, by default 0. | |
| void | Rebind (const occ::handle< Standard_Transient > &start, const occ::handle< Transfer_Binder > &binder) |
| Changes the Binder linked with a starting Object for its unitary transfer. This it can be useful when the exact form of the result is known once the transfer is widely engaged. This can be done only on first transfer. Considers a category number, by default 0. | |
| bool | Unbind (const occ::handle< Standard_Transient > &start) |
| Removes the Binder linked with a starting object If this Binder brings a non-empty Check, it is replaced by a VoidBinder. Also removes from the list of Roots as required. Returns True if done, False if <start> was not bound Considers a category number, by default 0. | |
| occ::handle< Transfer_Binder > | FindElseBind (const occ::handle< Standard_Transient > &start) |
| Returns a Binder for a starting entity, as follows : Tries to Find the already bound one If none found, creates a VoidBinder and Binds it. | |
| void | SetMessenger (const occ::handle< Message_Messenger > &messenger) |
| Sets Messenger used for outputting messages. | |
| occ::handle< Message_Messenger > | Messenger () const |
| Returns Messenger used for outputting messages. The returned object is guaranteed to be non-null; default is Message::Messenger(). | |
| void | SetTraceLevel (const int tracelev) |
| Sets trace level used for outputting messages: <trace> = 0 : no trace at all <trace> = 1 : handled exceptions and calls to AddError <trace> = 2 : also calls to AddWarning <trace> = 3 : also traces new Roots (uses method ErrorTrace). Default is 1 : Errors traced. | |
| int | TraceLevel () const |
| Returns trace level used for outputting messages. | |
| void | SendFail (const occ::handle< Standard_Transient > &start, const Message_Msg &amsg) |
| New name for AddFail (Msg) | |
| void | SendWarning (const occ::handle< Standard_Transient > &start, const Message_Msg &amsg) |
| New name for AddWarning (Msg) | |
| void | SendMsg (const occ::handle< Standard_Transient > &start, const Message_Msg &amsg) |
| Adds an information message Trace is filled if trace level is at least 3. | |
| void | AddFail (const occ::handle< Standard_Transient > &start, const char *const mess, const char *const orig="") |
| Adds an Error message to a starting entity (to the check of its Binder of category 0, as a Fail) | |
| void | AddError (const occ::handle< Standard_Transient > &start, const char *const mess, const char *const orig="") |
| (other name of AddFail, maintained for compatibility) | |
| void | AddFail (const occ::handle< Standard_Transient > &start, const Message_Msg &amsg) |
| Adds an Error Message to a starting entity from the definition of a Msg (Original+Value) | |
| void | AddWarning (const occ::handle< Standard_Transient > &start, const char *const mess, const char *const orig="") |
| Adds a Warning message to a starting entity (to the check of its Binder of category 0) | |
| void | AddWarning (const occ::handle< Standard_Transient > &start, const Message_Msg &amsg) |
| Adds a Warning Message to a starting entity from the definition of a Msg (Original+Value) | |
| void | Mend (const occ::handle< Standard_Transient > &start, const char *const pref="") |
| occ::handle< Interface_Check > | Check (const occ::handle< Standard_Transient > &start) const |
| Returns the Check attached to a starting entity. If <start> is unknown, returns an empty Check Adds a case name to a starting entity Adds a case value to a starting entity Returns the complete case list for an entity. Null Handle if empty In the list of mapped items (between 1 and NbMapped), searches for the first item which follows <num0>(not included) and which has an attribute named <name> Attributes are brought by Binders Hence, allows such an iteration. | |
| void | BindTransient (const occ::handle< Standard_Transient > &start, const occ::handle< Standard_Transient > &res) |
| Binds a starting object with a Transient Result. Uses a SimpleBinderOfTransient to work. If there is already one but with no Result set, sets its Result. Considers a category number, by default 0. | |
| const occ::handle< Standard_Transient > & | FindTransient (const occ::handle< Standard_Transient > &start) const |
| Returns the Result of the Transfer of an object <start> as a Transient Result. Returns a Null Handle if there is no Transient Result Considers a category number, by default 0 Warning : Supposes that Binding is done with a SimpleBinderOfTransient. | |
| void | BindMultiple (const occ::handle< Standard_Transient > &start) |
| Prepares an object <start> to be bound with several results. If no Binder is yet attached to <obj>, a MultipleBinder is created, empty. If a Binder is already set, it must accept Multiple Binding. Considers a category number, by default 0. | |
| void | AddMultiple (const occ::handle< Standard_Transient > &start, const occ::handle< Standard_Transient > &res) |
| Adds an item to a list of results bound to a starting object. Considers a category number, by default 0, for all results. | |
| bool | FindTypedTransient (const occ::handle< Standard_Transient > &start, const occ::handle< Standard_Type > &atype, occ::handle< Standard_Transient > &val) const |
| Searches for a transient result attached to a starting object, according to its type, by criterium IsKind(atype) | |
| bool | GetTypedTransient (const occ::handle< Transfer_Binder > &binder, const occ::handle< Standard_Type > &atype, occ::handle< Standard_Transient > &val) const |
| Searches for a transient result recorded in a Binder, whatever this Binder is recorded or not in <me> | |
| int | NbMapped () const |
| Returns the maximum possible value for Map Index (no result can be bound with a value greater than it) | |
| const occ::handle< Standard_Transient > & | Mapped (const int num) const |
| Returns the Starting Object bound to an Index,. | |
| int | MapIndex (const occ::handle< Standard_Transient > &start) const |
| Returns the Index value bound to a Starting Object, 0 if none. | |
| occ::handle< Transfer_Binder > | MapItem (const int num) const |
| Returns the Binder bound to an Index Considers a category number, by default 0. | |
| void | SetRoot (const occ::handle< Standard_Transient > &start) |
| Declares <obj> (and its Result) as Root. This status will be later exploited by RootResult, see below (Result can be produced at any time) | |
| void | SetRootManagement (const bool stat) |
| Enable (if <stat> True) or Disables (if <stat> False) Root Management. If it is set, Transfers are considered as stacked (a first Transfer commands other Transfers, and so on) and the Transfers commanded by an external caller are "Root". Remark : SetRoot can be called whatever this status, on every object. Default is set to True. | |
| int | NbRoots () const |
| Returns the count of recorded Roots. | |
| const occ::handle< Standard_Transient > & | Root (const int num) const |
| Returns a Root Entity given its number in the list (1-NbRoots) | |
| occ::handle< Transfer_Binder > | RootItem (const int num) const |
| Returns the Binder bound with a Root Entity given its number Considers a category number, by default 0. | |
| int | RootIndex (const occ::handle< Standard_Transient > &start) const |
| Returns the index in the list of roots for a starting item, or 0 if it is not recorded as a root. | |
| int | NestingLevel () const |
| Returns Nesting Level of Transfers (managed by methods TranscriptWith & Co). Starts to zero. If no automatic Transfer is used, it remains to zero. Zero means Root Level. | |
| void | ResetNestingLevel () |
| Resets Nesting Level of Transfers to Zero (Root Level), whatever its current value. | |
| bool | Recognize (const occ::handle< Standard_Transient > &start) const |
| Tells if <start> has been recognized as good candidate for Transfer. i.e. queries the Actor and its Nexts. | |
| occ::handle< Transfer_Binder > | Transferring (const occ::handle< Standard_Transient > &start, const Message_ProgressRange &theProgress=Message_ProgressRange()) |
| Performs the Transfer of a Starting Object, by calling the method TransferProduct (see below). Mapping and Roots are managed : nothing is done if a Result is already Bound, an exception is raised in case of error. | |
| bool | Transfer (const occ::handle< Standard_Transient > &start, const Message_ProgressRange &theProgress=Message_ProgressRange()) |
| Same as Transferring but does not return the Binder. Simply returns True in case of success (for user call) | |
| void | SetErrorHandle (const bool err) |
| Allows controls if exceptions will be handled Transfer Operations <err> False : they are not handled with try {} catch {} <err> True : they are Default is False: no handling performed. | |
| bool | ErrorHandle () const |
| Returns error handling flag. | |
| void | StartTrace (const occ::handle< Transfer_Binder > &binder, const occ::handle< Standard_Transient > &start, const int level, const int mode) const |
| Method called when trace is asked Calls PrintTrace to display information relevant for starting objects (which can be redefined) <level> is Nesting Level of Transfer (0 = root) <mode> controls the way the trace is done : 0 neutral, 1 for Error, 2 for Warning message, 3 for new Root. | |
| virtual void | PrintTrace (const occ::handle< Standard_Transient > &start, Standard_OStream &S) const |
| Prints a short information on a starting object. By default prints its Dynamic Type. Can be redefined. | |
| bool | IsLooping (const int alevel) const |
| Returns True if we are surely in a DeadLoop. Evaluation is not exact, it is a "majorant" which must be computed fast. This "majorant" is : <alevel> greater than NbMapped. | |
| Transfer_IteratorOfProcessForTransient | RootResult (const bool withstart=false) const |
| Returns, as an iterator, the log of root transfer, i.e. the created objects and Binders bound to starting roots If withstart is given True, Starting Objects are also returned. | |
| Transfer_IteratorOfProcessForTransient | CompleteResult (const bool withstart=false) const |
| Returns, as an Iterator, the entire log of transfer (list of created objects and Binders which can bring errors) If withstart is given True, Starting Objects are also returned. | |
| Transfer_IteratorOfProcessForTransient | AbnormalResult () const |
| Returns Binders which are neither "Done" nor "Initial", that is Error,Loop or Run (abnormal states at end of Transfer) Starting Objects are given in correspondence in the iterator. | |
| Interface_CheckIterator | CheckList (const bool erronly) const |
| Returns a CheckList as a list of Check : each one is for a starting entity which have either check (warning or fail) messages are attached, or are in abnormal state : that case gives a specific message If <erronly> is True, checks with Warnings only are ignored. | |
| Transfer_IteratorOfProcessForTransient | ResultOne (const occ::handle< Standard_Transient > &start, const int level, const bool withstart=false) const |
| Returns, as an Iterator, the log of transfer for one object <level> = 0 : this object only and if <start> is a scope owner (else, <level> is ignored) : <level> = 1 : object plus its immediate scoped ones <level> = 2 : object plus all its scoped ones. | |
| Interface_CheckIterator | CheckListOne (const occ::handle< Standard_Transient > &start, const int level, const bool erronly) const |
| Returns a CheckList for one starting object <level> interpreted as by ResultOne If <erronly> is True, checks with Warnings only are ignored. | |
| bool | IsCheckListEmpty (const occ::handle< Standard_Transient > &start, const int level, const bool erronly) const |
| Returns True if no check message is attached to a starting object. <level> interpreted as by ResultOne If <erronly> is True, checks with Warnings only are ignored. | |
| void | RemoveResult (const occ::handle< Standard_Transient > &start, const int level, const bool compute=true) |
| Removes Results attached to (== Unbinds) a given object and, according <level> : <level> = 0 : only it <level> = 1 : it plus its immediately owned sub-results(scope) <level> = 2 : it plus all its owned sub-results(scope) | |
| virtual int | CheckNum (const occ::handle< Standard_Transient > &start) const |
| Computes a number to be associated to a starting object in a check or a check-list By default, returns 0; can be redefined. | |
Public Member Functions inherited from Standard_Transient | |
| Standard_Transient () | |
| Empty constructor. | |
| Standard_Transient (const Standard_Transient &) | |
| Copy constructor – does nothing. | |
| Standard_Transient & | operator= (const Standard_Transient &) |
| Assignment operator, needed to avoid copying reference counter. | |
| virtual | ~Standard_Transient ()=default |
| Destructor must be virtual. | |
| virtual const opencascade::handle< Standard_Type > & | DynamicType () const |
| Returns a type descriptor about this object. | |
| bool | IsInstance (const opencascade::handle< Standard_Type > &theType) const |
| Returns a true value if this is an instance of Type. | |
| bool | IsInstance (const char *const theTypeName) const |
| Returns a true value if this is an instance of TypeName. | |
| bool | IsKind (const opencascade::handle< Standard_Type > &theType) const |
| Returns true if this is an instance of Type or an instance of any class that inherits from Type. Note that multiple inheritance is not supported by OCCT RTTI mechanism. | |
| bool | IsKind (const char *const theTypeName) const |
| Returns true if this is an instance of TypeName or an instance of any class that inherits from TypeName. Note that multiple inheritance is not supported by OCCT RTTI mechanism. | |
| Standard_Transient * | This () const |
| Returns non-const pointer to this object (like const_cast). For protection against creating handle to objects allocated in stack or call from constructor, it will raise exception Standard_ProgramError if reference counter is zero. | |
| int | GetRefCount () const noexcept |
| Get the reference counter of this object. | |
| void | IncrementRefCounter () noexcept |
| Increments the reference counter of this object. Uses relaxed memory ordering since incrementing only requires atomicity, not synchronization with other memory operations. | |
| int | DecrementRefCounter () noexcept |
| Decrements the reference counter of this object; returns the decremented value. Uses release ordering for the decrement to ensure all writes to the object are visible before the count reaches zero. An acquire fence is added only when the count reaches zero, ensuring proper synchronization before deletion. This is more efficient than using acq_rel for every decrement. | |
| virtual void | Delete () const |
| Memory deallocator for transient classes. | |
Additional Inherited Members | |
Public Types inherited from Standard_Transient | |
| typedef void | base_type |
| Returns a type descriptor about this object. | |
Static Public Member Functions inherited from Standard_Transient | |
| static constexpr const char * | get_type_name () |
| Returns a type descriptor about this object. | |
| static const opencascade::handle< Standard_Type > & | get_type_descriptor () |
| Returns type descriptor of Standard_Transient class. | |
Manages Transfer of Transient Objects. Produces also ActorOfTransientProcess (deferred class), IteratorOfTransientProcess (for Results), TransferMapOfTransientProcess (internally used) Normally uses as TransientProcess, which adds some specifics.
| Transfer_ProcessForTransient::Transfer_ProcessForTransient | ( | const int | nb = 10000 | ) |
Sets TransferProcess at initial state. Gives an Initial size (indicative) for the Map when known (default is 10000). Sets default trace file as a printer and default trace level (see Message_TraceFile).
| Transfer_ProcessForTransient::Transfer_ProcessForTransient | ( | const occ::handle< Message_Messenger > & | printer, |
| const int | nb = 10000 ) |
Sets TransferProcess at initial state. Gives an Initial size (indicative) for the Map when known (default is 10000). Sets a specified printer.
| Transfer_IteratorOfProcessForTransient Transfer_ProcessForTransient::AbnormalResult | ( | ) | const |
Returns Binders which are neither "Done" nor "Initial", that is Error,Loop or Run (abnormal states at end of Transfer) Starting Objects are given in correspondence in the iterator.
| occ::handle< Transfer_ActorOfProcessForTransient > Transfer_ProcessForTransient::Actor | ( | ) | const |
Returns the defined Actor. Returns a Null Handle if not set.
| void Transfer_ProcessForTransient::AddError | ( | const occ::handle< Standard_Transient > & | start, |
| const char *const | mess, | ||
| const char *const | orig = "" ) |
(other name of AddFail, maintained for compatibility)
| void Transfer_ProcessForTransient::AddFail | ( | const occ::handle< Standard_Transient > & | start, |
| const char *const | mess, | ||
| const char *const | orig = "" ) |
Adds an Error message to a starting entity (to the check of its Binder of category 0, as a Fail)
| void Transfer_ProcessForTransient::AddFail | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_Msg & | amsg ) |
Adds an Error Message to a starting entity from the definition of a Msg (Original+Value)
| void Transfer_ProcessForTransient::AddMultiple | ( | const occ::handle< Standard_Transient > & | start, |
| const occ::handle< Standard_Transient > & | res ) |
Adds an item to a list of results bound to a starting object. Considers a category number, by default 0, for all results.
| void Transfer_ProcessForTransient::AddWarning | ( | const occ::handle< Standard_Transient > & | start, |
| const char *const | mess, | ||
| const char *const | orig = "" ) |
Adds a Warning message to a starting entity (to the check of its Binder of category 0)
| void Transfer_ProcessForTransient::AddWarning | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_Msg & | amsg ) |
Adds a Warning Message to a starting entity from the definition of a Msg (Original+Value)
| void Transfer_ProcessForTransient::Bind | ( | const occ::handle< Standard_Transient > & | start, |
| const occ::handle< Transfer_Binder > & | binder ) |
Creates a Link a starting Object with a Binder. This Binder can either bring a Result (effective Binding) or none (it can be set later : pre-binding). Considers a category number, by default 0.
| void Transfer_ProcessForTransient::BindMultiple | ( | const occ::handle< Standard_Transient > & | start | ) |
Prepares an object <start> to be bound with several results. If no Binder is yet attached to <obj>, a MultipleBinder is created, empty. If a Binder is already set, it must accept Multiple Binding. Considers a category number, by default 0.
| void Transfer_ProcessForTransient::BindTransient | ( | const occ::handle< Standard_Transient > & | start, |
| const occ::handle< Standard_Transient > & | res ) |
Binds a starting object with a Transient Result. Uses a SimpleBinderOfTransient to work. If there is already one but with no Result set, sets its Result. Considers a category number, by default 0.
| occ::handle< Interface_Check > Transfer_ProcessForTransient::Check | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns the Check attached to a starting entity. If <start> is unknown, returns an empty Check Adds a case name to a starting entity Adds a case value to a starting entity Returns the complete case list for an entity. Null Handle if empty In the list of mapped items (between 1 and NbMapped), searches for the first item which follows <num0>(not included) and which has an attribute named <name> Attributes are brought by Binders Hence, allows such an iteration.
for (num = TP->NextItemWithAttribute(name,0); num > 0; num = TP->NextItemWithAttribute(name,num) { .. process mapped item <num> } Returns the type of an Attribute attached to binders If this name gives no Attribute, returns ParamVoid If this name gives several different types, returns ParamMisc Else, returns the effective type (ParamInteger, ParamReal, ParamIdent, or ParamText) Returns the list of recorded Attribute Names, as a Dictionary of Integer : each value gives the count of items which bring this attribute name By default, considers all the attribute names If <rootname> is given, considers only the attribute names which begin by <rootname>
| Interface_CheckIterator Transfer_ProcessForTransient::CheckList | ( | const bool | erronly | ) | const |
Returns a CheckList as a list of Check : each one is for a starting entity which have either check (warning or fail) messages are attached, or are in abnormal state : that case gives a specific message If <erronly> is True, checks with Warnings only are ignored.
| Interface_CheckIterator Transfer_ProcessForTransient::CheckListOne | ( | const occ::handle< Standard_Transient > & | start, |
| const int | level, | ||
| const bool | erronly ) const |
Returns a CheckList for one starting object <level> interpreted as by ResultOne If <erronly> is True, checks with Warnings only are ignored.
|
virtual |
Computes a number to be associated to a starting object in a check or a check-list By default, returns 0; can be redefined.
Reimplemented in Transfer_TransientProcess.
| void Transfer_ProcessForTransient::Clean | ( | ) |
Rebuilds the Map and the roots to really remove Unbound items Because Unbind keeps the entity in place, even if not bound Hence, working by checking new items is meaningless if a formerly unbound item is rebound.
| void Transfer_ProcessForTransient::Clear | ( | ) |
Resets a TransferProcess as ready for a completely new work. Clears general data (roots) and the Map.
| Transfer_IteratorOfProcessForTransient Transfer_ProcessForTransient::CompleteResult | ( | const bool | withstart = false | ) | const |
Returns, as an Iterator, the entire log of transfer (list of created objects and Binders which can bring errors) If withstart is given True, Starting Objects are also returned.
| bool Transfer_ProcessForTransient::ErrorHandle | ( | ) | const |
Returns error handling flag.
| occ::handle< Transfer_Binder > Transfer_ProcessForTransient::Find | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns the Binder which is linked with a starting Object It can either bring a Result (Transfer done) or none (for a pre-binding). If no Binder is linked with <start>, returns a Null Handle Considers a category number, by default 0.
| occ::handle< Transfer_Binder > Transfer_ProcessForTransient::FindElseBind | ( | const occ::handle< Standard_Transient > & | start | ) |
Returns a Binder for a starting entity, as follows : Tries to Find the already bound one If none found, creates a VoidBinder and Binds it.
| const occ::handle< Standard_Transient > & Transfer_ProcessForTransient::FindTransient | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns the Result of the Transfer of an object <start> as a Transient Result. Returns a Null Handle if there is no Transient Result Considers a category number, by default 0 Warning : Supposes that Binding is done with a SimpleBinderOfTransient.
| bool Transfer_ProcessForTransient::FindTypedTransient | ( | const occ::handle< Standard_Transient > & | start, |
| const occ::handle< Standard_Type > & | atype, | ||
| occ::handle< Standard_Transient > & | val ) const |
Searches for a transient result attached to a starting object, according to its type, by criterium IsKind(atype)
In case of multiple result, explores the list and gives in <val> the first transient result IsKind(atype) Returns True and fills <val> if found Else, returns False (<val> is not touched, not even nullified)
This syntactic form avoids to do DownCast : if a result is found with the good type, it is loaded in <val> and can be immediately used, well initialised
| bool Transfer_ProcessForTransient::GetTypedTransient | ( | const occ::handle< Transfer_Binder > & | binder, |
| const occ::handle< Standard_Type > & | atype, | ||
| occ::handle< Standard_Transient > & | val ) const |
Searches for a transient result recorded in a Binder, whatever this Binder is recorded or not in <me>
This is strictly equivalent to the class method GetTypedResult from class SimpleBinderOfTransient, but is just lighter to call
Apart from this, works as FindTypedTransient
| bool Transfer_ProcessForTransient::IsAlreadyUsed | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns True if the result of the transfer of an object is already used in other ones. If it is, Rebind cannot change it. Considers a category number, by default 0.
| bool Transfer_ProcessForTransient::IsBound | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns True if a Result (whatever its form) is Bound with a starting Object. I.e., if a Binder with a Result set, is linked with it Considers a category number, by default 0.
| bool Transfer_ProcessForTransient::IsCheckListEmpty | ( | const occ::handle< Standard_Transient > & | start, |
| const int | level, | ||
| const bool | erronly ) const |
Returns True if no check message is attached to a starting object. <level> interpreted as by ResultOne If <erronly> is True, checks with Warnings only are ignored.
Returns True if we are surely in a DeadLoop. Evaluation is not exact, it is a "majorant" which must be computed fast. This "majorant" is : <alevel> greater than NbMapped.
| int Transfer_ProcessForTransient::MapIndex | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns the Index value bound to a Starting Object, 0 if none.
| occ::handle< Transfer_Binder > Transfer_ProcessForTransient::MapItem | ( | const int | num | ) | const |
Returns the Binder bound to an Index Considers a category number, by default 0.
| const occ::handle< Standard_Transient > & Transfer_ProcessForTransient::Mapped | ( | const int | num | ) | const |
Returns the Starting Object bound to an Index,.
| void Transfer_ProcessForTransient::Mend | ( | const occ::handle< Standard_Transient > & | start, |
| const char *const | pref = "" ) |
| occ::handle< Message_Messenger > Transfer_ProcessForTransient::Messenger | ( | ) | const |
Returns Messenger used for outputting messages. The returned object is guaranteed to be non-null; default is Message::Messenger().
| int Transfer_ProcessForTransient::NbMapped | ( | ) | const |
Returns the maximum possible value for Map Index (no result can be bound with a value greater than it)
| int Transfer_ProcessForTransient::NbRoots | ( | ) | const |
Returns the count of recorded Roots.
| int Transfer_ProcessForTransient::NestingLevel | ( | ) | const |
Returns Nesting Level of Transfers (managed by methods TranscriptWith & Co). Starts to zero. If no automatic Transfer is used, it remains to zero. Zero means Root Level.
|
virtual |
Prints a short information on a starting object. By default prints its Dynamic Type. Can be redefined.
Reimplemented in Transfer_TransientProcess.
| void Transfer_ProcessForTransient::Rebind | ( | const occ::handle< Standard_Transient > & | start, |
| const occ::handle< Transfer_Binder > & | binder ) |
Changes the Binder linked with a starting Object for its unitary transfer. This it can be useful when the exact form of the result is known once the transfer is widely engaged. This can be done only on first transfer. Considers a category number, by default 0.
| bool Transfer_ProcessForTransient::Recognize | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Tells if <start> has been recognized as good candidate for Transfer. i.e. queries the Actor and its Nexts.
| void Transfer_ProcessForTransient::RemoveResult | ( | const occ::handle< Standard_Transient > & | start, |
| const int | level, | ||
| const bool | compute = true ) |
Removes Results attached to (== Unbinds) a given object and, according <level> : <level> = 0 : only it <level> = 1 : it plus its immediately owned sub-results(scope) <level> = 2 : it plus all its owned sub-results(scope)
| void Transfer_ProcessForTransient::ResetNestingLevel | ( | ) |
Resets Nesting Level of Transfers to Zero (Root Level), whatever its current value.
Resizes the Map as required (if a new reliable value has been determined). Acts only if <nb> is greater than actual NbMapped.
| Transfer_IteratorOfProcessForTransient Transfer_ProcessForTransient::ResultOne | ( | const occ::handle< Standard_Transient > & | start, |
| const int | level, | ||
| const bool | withstart = false ) const |
Returns, as an Iterator, the log of transfer for one object <level> = 0 : this object only and if <start> is a scope owner (else, <level> is ignored) : <level> = 1 : object plus its immediate scoped ones <level> = 2 : object plus all its scoped ones.
| const occ::handle< Standard_Transient > & Transfer_ProcessForTransient::Root | ( | const int | num | ) | const |
Returns a Root Entity given its number in the list (1-NbRoots)
| int Transfer_ProcessForTransient::RootIndex | ( | const occ::handle< Standard_Transient > & | start | ) | const |
Returns the index in the list of roots for a starting item, or 0 if it is not recorded as a root.
| occ::handle< Transfer_Binder > Transfer_ProcessForTransient::RootItem | ( | const int | num | ) | const |
Returns the Binder bound with a Root Entity given its number Considers a category number, by default 0.
| Transfer_IteratorOfProcessForTransient Transfer_ProcessForTransient::RootResult | ( | const bool | withstart = false | ) | const |
Returns, as an iterator, the log of root transfer, i.e. the created objects and Binders bound to starting roots If withstart is given True, Starting Objects are also returned.
| void Transfer_ProcessForTransient::SendFail | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_Msg & | amsg ) |
New name for AddFail (Msg)
| void Transfer_ProcessForTransient::SendMsg | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_Msg & | amsg ) |
Adds an information message Trace is filled if trace level is at least 3.
| void Transfer_ProcessForTransient::SendWarning | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_Msg & | amsg ) |
New name for AddWarning (Msg)
| void Transfer_ProcessForTransient::SetActor | ( | const occ::handle< Transfer_ActorOfProcessForTransient > & | actor | ) |
Defines an Actor, which is used for automatic Transfer If already defined, the new Actor is cumulated (see SetNext from Actor)
Allows controls if exceptions will be handled Transfer Operations <err> False : they are not handled with try {} catch {} <err> True : they are Default is False: no handling performed.
| void Transfer_ProcessForTransient::SetMessenger | ( | const occ::handle< Message_Messenger > & | messenger | ) |
Sets Messenger used for outputting messages.
| void Transfer_ProcessForTransient::SetRoot | ( | const occ::handle< Standard_Transient > & | start | ) |
Declares <obj> (and its Result) as Root. This status will be later exploited by RootResult, see below (Result can be produced at any time)
Enable (if <stat> True) or Disables (if <stat> False) Root Management. If it is set, Transfers are considered as stacked (a first Transfer commands other Transfers, and so on) and the Transfers commanded by an external caller are "Root". Remark : SetRoot can be called whatever this status, on every object. Default is set to True.
Sets trace level used for outputting messages: <trace> = 0 : no trace at all <trace> = 1 : handled exceptions and calls to AddError <trace> = 2 : also calls to AddWarning <trace> = 3 : also traces new Roots (uses method ErrorTrace). Default is 1 : Errors traced.
| void Transfer_ProcessForTransient::StartTrace | ( | const occ::handle< Transfer_Binder > & | binder, |
| const occ::handle< Standard_Transient > & | start, | ||
| const int | level, | ||
| const int | mode ) const |
Method called when trace is asked Calls PrintTrace to display information relevant for starting objects (which can be redefined) <level> is Nesting Level of Transfer (0 = root) <mode> controls the way the trace is done : 0 neutral, 1 for Error, 2 for Warning message, 3 for new Root.
| int Transfer_ProcessForTransient::TraceLevel | ( | ) | const |
Returns trace level used for outputting messages.
| bool Transfer_ProcessForTransient::Transfer | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_ProgressRange & | theProgress = Message_ProgressRange() ) |
Same as Transferring but does not return the Binder. Simply returns True in case of success (for user call)
| occ::handle< Transfer_Binder > Transfer_ProcessForTransient::Transferring | ( | const occ::handle< Standard_Transient > & | start, |
| const Message_ProgressRange & | theProgress = Message_ProgressRange() ) |
Performs the Transfer of a Starting Object, by calling the method TransferProduct (see below). Mapping and Roots are managed : nothing is done if a Result is already Bound, an exception is raised in case of error.
| bool Transfer_ProcessForTransient::Unbind | ( | const occ::handle< Standard_Transient > & | start | ) |
Removes the Binder linked with a starting object If this Binder brings a non-empty Check, it is replaced by a VoidBinder. Also removes from the list of Roots as required. Returns True if done, False if <start> was not bound Considers a category number, by default 0.