# DataExchange
TKXSBase
Interface

# Interface_ShareTool Class Reference

Builds the Graph of Dependancies, from the General Service
"Shared" -> builds for each Entity of a Model, the Shared and
Sharing Lists, and gives access to them.
Allows to complete with Implied References (which are not
regarded as Shared Entities, but are nevertheless Referenced),
this can be usefull for Reference Checking
.

`#include <Interface_ShareTool.hxx>`

## Public Member Functions

void * | operator new (size_t, void *anAddress)
void * | operator new (size_t size)
void | operator delete (void *anAddress)
Standard_EXPORT | Interface_ShareTool (const Handle(Interface_InterfaceModel)&amodel, const Interface_GeneralLib &lib)
| Creates a ShareTool from a Model and builds all required data, by calling the General Service Library and Modules (GeneralLib given as an argument) .
Standard_EXPORT | Interface_ShareTool (const Handle(Interface_InterfaceModel)&amodel, const Handle(Interface_GTool)&gtool)
| Same a above, but GeneralLib is detained by a GTool .
Standard_EXPORT | Interface_ShareTool (const Handle(Interface_InterfaceModel)&amodel, const Handle(Interface_Protocol)&protocol)
| Same a above, but GeneralLib is defined through a Protocol Protocol is used to build the working library .
Standard_EXPORT | Interface_ShareTool (const Handle(Interface_InterfaceModel)&amodel)
| Same as above, but works with the GTool of the Model .
Standard_EXPORT | Interface_ShareTool (const Interface_Graph &agraph)
| Creates a ShareTool from an already defined Graph Remark that the data of the Graph are copied .
Standard_EXPORT | Interface_ShareTool (const Handle(Interface_HGraph)&ahgraph)
Standard_EXPORT void | AddImplied (const Handle(Interface_GTool)&gtool)
| Completes the Graph by Adding Implied References. Hence, they are considered as Sharing References in all the other queries .
Standard_EXPORT Handle_Interface_InterfaceModel | Model () const
| Returns the Model used for Creation (directly or for Graph) .
Standard_EXPORT const Interface_Graph & | Graph () const
| Returns the data used by the ShareTool to work Can then be used directly (read only) .
Standard_EXPORT Interface_EntityIterator | RootEntities () const
| Returns the Entities which are not Shared (their Sharing List is empty) in the Model .
Standard_EXPORT Standard_Boolean | IsShared (const Handle(Standard_Transient)&ent) const
| Returns True if <ent> is Shared by other Entities in the Model .
Standard_EXPORT Interface_EntityIterator | Shareds (const Handle(Standard_Transient)&ent) const
| Returns the List of Entities Shared by a given Entity <ent> .
Standard_EXPORT Interface_EntityIterator | Sharings (const Handle(Standard_Transient)&ent) const
| Returns the List of Entities Sharing a given Entity <ent> .
Standard_EXPORT Standard_Integer | NbTypedSharings (const Handle(Standard_Transient)&ent, const Handle(Standard_Type)&atype) const
| Returns the count of Sharing Entities of an Entity, which are Kind of a given Type .
Standard_EXPORT Handle_Standard_Transient | TypedSharing (const Handle(Standard_Transient)&ent, const Handle(Standard_Type)&atype) const
| Returns the Sharing Entity of an Entity, which is Kind of a given Type. Allows to access a Sharing Entity of a given type when there is one and only one (current case) .
Standard_EXPORT Interface_EntityIterator | All (const Handle(Standard_Transient)&ent, const Standard_Boolean rootlast=Standard_True) const
| Returns the complete list of entities shared by <ent> at any level, including <ent> itself If <ent> is the Model, considers the concatenation of AllShared for each root If <rootlast> is True (D), the list starts with lower level entities and ends by the root. Else, the root is first and the lower level entities are at end .
Standard_EXPORT void | Print (const Interface_EntityIterator &iter, const Handle(Message_Messenger)&S) const
| Utility method which Prints the content of an iterator (by their Numbers) .

## Private Attributes

Handle_Interface_HGraph | theHGraph

## Constructor & Destructor Documentation

Standard_EXPORT Interface_ShareTool::Interface_ShareTool | ( | const Handle(Interface_InterfaceModel)& | amodel,
|  | const Interface_GeneralLib & | lib
| ) |

Standard_EXPORT Interface_ShareTool::Interface_ShareTool | ( | const Handle(Interface_InterfaceModel)& | amodel,
|  | const Handle(Interface_GTool)& | gtool
| ) |

Standard_EXPORT Interface_ShareTool::Interface_ShareTool | ( | const Handle(Interface_InterfaceModel)& | amodel,
|  | const Handle(Interface_Protocol)& | protocol
| ) |

Standard_EXPORT Interface_ShareTool::Interface_ShareTool | ( | const Handle(Interface_InterfaceModel)& | amodel | ) |

Standard_EXPORT Interface_ShareTool::Interface_ShareTool | ( | const Interface_Graph & | agraph | ) |

Standard_EXPORT Interface_ShareTool::Interface_ShareTool | ( | const Handle(Interface_HGraph)& | ahgraph | ) |

## Member Function Documentation

Standard_EXPORT void Interface_ShareTool::AddImplied | ( | const Handle(Interface_GTool)& | gtool | ) |

Standard_EXPORT Interface_EntityIterator Interface_ShareTool::All | ( | const Handle(Standard_Transient)& | ent,
|  | const Standard_Boolean | rootlast = `Standard_True`
| ) | const

Standard_EXPORT const Interface_Graph& Interface_ShareTool::Graph | ( |  | ) | const

Standard_EXPORT Standard_Boolean Interface_ShareTool::IsShared | ( | const Handle(Standard_Transient)& | ent | ) | const

Standard_EXPORT Handle_Interface_InterfaceModel Interface_ShareTool::Model | ( |  | ) | const

Standard_EXPORT Standard_Integer Interface_ShareTool::NbTypedSharings | ( | const Handle(Standard_Transient)& | ent,
|  | const Handle(Standard_Type)& | atype
| ) | const

void Interface_ShareTool::operator delete | ( | void * | anAddress | ) | `[inline]`

void* Interface_ShareTool::operator new | ( | size_t | size | ) | `[inline]`

void* Interface_ShareTool::operator new | ( | size_t | ,
|  | void * | anAddress
| ) | `[inline]`

Standard_EXPORT void Interface_ShareTool::Print | ( | const Interface_EntityIterator & | iter,
|  | const Handle(Message_Messenger)& | S
| ) | const

Standard_EXPORT Interface_EntityIterator Interface_ShareTool::RootEntities | ( |  | ) | const

Standard_EXPORT Interface_EntityIterator Interface_ShareTool::Shareds | ( | const Handle(Standard_Transient)& | ent | ) | const

Standard_EXPORT Interface_EntityIterator Interface_ShareTool::Sharings | ( | const Handle(Standard_Transient)& | ent | ) | const

Standard_EXPORT Handle_Standard_Transient Interface_ShareTool::TypedSharing | ( | const Handle(Standard_Transient)& | ent,
|  | const Handle(Standard_Type)& | atype
| ) | const

## Field Documentation

Handle_Interface_HGraph Interface_ShareTool::theHGraph `[private]`

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

- Interface_ShareTool.hxx