OCC Main Page | ModelingData | Toolkits | Packages | Class Hierarchy | Data Structures | File List | Data Fields | Globals

ModelingData
TKBRep
TopTools


TopTools_ShapeSet Class Reference

A ShapeSets contains a Shape and all its
sub-shapes and locations. It can be dump, write
and read.

Methods to handle the geometry can be redefined.

.

#include <TopTools_ShapeSet.hxx>

Inheritance diagram for TopTools_ShapeSet:

Inheritance graph
[legend]

Public Member Functions

void * operator new (size_t, void *anAddress)
void * operator new (size_t size)
void operator delete (void *anAddress)
Standard_EXPORT TopTools_ShapeSet ()
 Builds an empty ShapeSet.
.
virtual Standard_EXPORT void Delete ()
virtual Standard_EXPORT ~TopTools_ShapeSet ()
Standard_EXPORT void SetFormatNb (const Standard_Integer theFormatNb)
Standard_EXPORT Standard_Integer FormatNb () const
 two formats available for the moment:
First: does not write CurveOnSurface UV Points into the file
on reading calls Check() method.
Second: stores CurveOnSurface UV Points.
On reading format is recognized from Version string.

virtual Standard_EXPORT void Clear ()
 Clears the content of the set. This method can be
redefined.
.
Standard_EXPORT Standard_Integer Add (const TopoDS_Shape &S)
 Stores <s> and its sub-shape. Returns the index of <s>.
The method AddGeometry is called on each sub-shape.
.
Standard_EXPORT const TopoDS_ShapeShape (const Standard_Integer I) const
 Returns the sub-shape of index .

.

Standard_EXPORT Standard_Integer Index (const TopoDS_Shape &S) const
 Returns the index of <s>.
.
Standard_EXPORT const TopTools_LocationSetLocations () const
Standard_EXPORT TopTools_LocationSetChangeLocations ()
Standard_EXPORT Standard_OStream & DumpExtent (Standard_OStream &OS) const
 Dumps the number of objects in me on the stream <os>.
(Number of shapes of each type)
.
Standard_EXPORT void DumpExtent (TCollection_AsciiString &S) const
 Dumps the number of objects in me in the string S
(Number of shapes of each type)
.
virtual Standard_EXPORT void Dump (Standard_OStream &OS) const
 Dumps the content of me on the stream <os>.

Dumps the shapes from first to last.
For each Shape
Dump the type, the flags, the subshapes
calls DumpGeometry(S)


Dumps the geometry calling DumpGeometry.

Dumps the locations.
.
virtual Standard_EXPORT void Write (Standard_OStream &OS)
 Writes the content of me on the stream <os> in a
format that can be read back by Read.

Writes the locations.

Writes the geometry calling WriteGeometry.

Dumps the shapes from last to first.
For each shape :
Write the type.
calls WriteGeometry(S).
Write the flags, the subshapes.
.
virtual Standard_EXPORT void Read (Standard_IStream &IS)
 Reads the content of me from the stream <is>. me
is first cleared.

Reads the locations.

Reads the geometry calling ReadGeometry.

Reads the shapes.
For each shape
Reads the type.
calls ReadGeometry(T,S).
Reads the flag, the subshapes.
.
Standard_EXPORT void Dump (const TopoDS_Shape &S, Standard_OStream &OS) const
 Dumps on <os> the shape <s>. Dumps the
orientation, the index of the TShape and the index
of the Location.
.
Standard_EXPORT void Write (const TopoDS_Shape &S, Standard_OStream &OS) const
 Writes on <os> the shape <s>. Writes the
orientation, the index of the TShape and the index
of the Location.
.
Standard_EXPORT void Read (TopoDS_Shape &S, Standard_IStream &IS) const
 Reads from <is> a shape and returns it in S.
.
virtual Standard_EXPORT void AddGeometry (const TopoDS_Shape &S)
 Stores the geometry of <s>.
.
virtual Standard_EXPORT void DumpGeometry (Standard_OStream &OS) const
 Dumps the geometry of me on the stream <os>.
.
virtual Standard_EXPORT void WriteGeometry (Standard_OStream &OS)
 Writes the geometry of me on the stream <os> in a
format that can be read back by Read.
.
virtual Standard_EXPORT void ReadGeometry (Standard_IStream &IS)
 Reads the geometry of me from the stream <is>.
.
virtual Standard_EXPORT void DumpGeometry (const TopoDS_Shape &S, Standard_OStream &OS) const
 Dumps the geometry of <s> on the stream <os>.
.
virtual Standard_EXPORT void WriteGeometry (const TopoDS_Shape &S, Standard_OStream &OS) const
 Writes the geometry of <s> on the stream <os> in a
format that can be read back by Read.
.
virtual Standard_EXPORT void ReadGeometry (const TopAbs_ShapeEnum T, Standard_IStream &IS, TopoDS_Shape &S)
 Reads the geometry of a shape of type <t> from the
stream <is> and returns it in <s>.
.
virtual Standard_EXPORT void AddShapes (TopoDS_Shape &S1, const TopoDS_Shape &S2)
 Inserts the shape <s2> in the shape <s1>. This
method must be redefined to use the correct
builder.
.
virtual Standard_EXPORT void Check (const TopAbs_ShapeEnum T, TopoDS_Shape &S)
 This method is called after each new completed
shape. <t> is the type. <s> is the shape. In this
class it does nothing, but it gives the opportunity
in derived classes to perform extra treatment on
shapes.
.
Standard_EXPORT Standard_Integer NbShapes () const
 Returns number of shapes read from file.
.
Standard_EXPORT void SetProgress (const Handle(Message_ProgressIndicator)&PR)
Standard_EXPORT Handle_Message_ProgressIndicator GetProgress () const

Private Member Functions

Standard_EXPORT void Read (TopoDS_Shape &S, Standard_IStream &IS, const Standard_Integer NbShapes) const
 Reads from <is> a shape and returns it in S.
<nbshapes> is the number of tshapes in the set.
.

Private Attributes

TopTools_IndexedMapOfShape myShapes
TopTools_LocationSet myLocations
Standard_Integer myFormatNb
Handle_Message_ProgressIndicator myProgress

Constructor & Destructor Documentation

Standard_EXPORT TopTools_ShapeSet::TopTools_ShapeSet  ) 
 

virtual Standard_EXPORT TopTools_ShapeSet::~TopTools_ShapeSet  )  [inline, virtual]
 


Member Function Documentation

Standard_EXPORT Standard_Integer TopTools_ShapeSet::Add const TopoDS_Shape S  ) 
 

virtual Standard_EXPORT void TopTools_ShapeSet::AddGeometry const TopoDS_Shape S  )  [virtual]
 

Reimplemented in BRepTools_ShapeSet.

virtual Standard_EXPORT void TopTools_ShapeSet::AddShapes TopoDS_Shape S1,
const TopoDS_Shape S2
[virtual]
 

Reimplemented in BRepTools_ShapeSet.

Standard_EXPORT TopTools_LocationSet& TopTools_ShapeSet::ChangeLocations  ) 
 

virtual Standard_EXPORT void TopTools_ShapeSet::Check const TopAbs_ShapeEnum  T,
TopoDS_Shape S
[virtual]
 

Reimplemented in BRepTools_ShapeSet.

virtual Standard_EXPORT void TopTools_ShapeSet::Clear  )  [virtual]
 

Reimplemented in BRepTools_ShapeSet.

virtual Standard_EXPORT void TopTools_ShapeSet::Delete  )  [virtual]
 

Standard_EXPORT void TopTools_ShapeSet::Dump const TopoDS_Shape S,
Standard_OStream &  OS
const
 

virtual Standard_EXPORT void TopTools_ShapeSet::Dump Standard_OStream &  OS  )  const [virtual]
 

Standard_EXPORT void TopTools_ShapeSet::DumpExtent TCollection_AsciiString &  S  )  const
 

Standard_EXPORT Standard_OStream& TopTools_ShapeSet::DumpExtent Standard_OStream &  OS  )  const
 

virtual Standard_EXPORT void TopTools_ShapeSet::DumpGeometry const TopoDS_Shape S,
Standard_OStream &  OS
const [virtual]
 

Reimplemented in BRepTools_ShapeSet.

virtual Standard_EXPORT void TopTools_ShapeSet::DumpGeometry Standard_OStream &  OS  )  const [virtual]
 

Reimplemented in BRepTools_ShapeSet.

Standard_EXPORT Standard_Integer TopTools_ShapeSet::FormatNb  )  const
 

Standard_EXPORT Handle_Message_ProgressIndicator TopTools_ShapeSet::GetProgress  )  const
 

Standard_EXPORT Standard_Integer TopTools_ShapeSet::Index const TopoDS_Shape S  )  const
 

Standard_EXPORT const TopTools_LocationSet& TopTools_ShapeSet::Locations  )  const
 

Standard_EXPORT Standard_Integer TopTools_ShapeSet::NbShapes  )  const
 

void TopTools_ShapeSet::operator delete void *  anAddress  )  [inline]
 

Reimplemented in BRepTools_ShapeSet.

void* TopTools_ShapeSet::operator new size_t  size  )  [inline]
 

Reimplemented in BRepTools_ShapeSet.

void* TopTools_ShapeSet::operator new size_t  ,
void *  anAddress
[inline]
 

Reimplemented in BRepTools_ShapeSet.

Standard_EXPORT void TopTools_ShapeSet::Read TopoDS_Shape S,
Standard_IStream &  IS,
const Standard_Integer  NbShapes
const [private]
 

Standard_EXPORT void TopTools_ShapeSet::Read TopoDS_Shape S,
Standard_IStream &  IS
const
 

virtual Standard_EXPORT void TopTools_ShapeSet::Read Standard_IStream &  IS  )  [virtual]
 

virtual Standard_EXPORT void TopTools_ShapeSet::ReadGeometry const TopAbs_ShapeEnum  T,
Standard_IStream &  IS,
TopoDS_Shape S
[virtual]
 

Reimplemented in BRepTools_ShapeSet.

virtual Standard_EXPORT void TopTools_ShapeSet::ReadGeometry Standard_IStream &  IS  )  [virtual]
 

Reimplemented in BRepTools_ShapeSet.

Standard_EXPORT void TopTools_ShapeSet::SetFormatNb const Standard_Integer  theFormatNb  ) 
 

Standard_EXPORT void TopTools_ShapeSet::SetProgress const Handle(Message_ProgressIndicator)&  PR  ) 
 

Standard_EXPORT const TopoDS_Shape& TopTools_ShapeSet::Shape const Standard_Integer  I  )  const
 

Standard_EXPORT void TopTools_ShapeSet::Write const TopoDS_Shape S,
Standard_OStream &  OS
const
 

virtual Standard_EXPORT void TopTools_ShapeSet::Write Standard_OStream &  OS  )  [virtual]
 

virtual Standard_EXPORT void TopTools_ShapeSet::WriteGeometry const TopoDS_Shape S,
Standard_OStream &  OS
const [virtual]
 

Reimplemented in BRepTools_ShapeSet.

virtual Standard_EXPORT void TopTools_ShapeSet::WriteGeometry Standard_OStream &  OS  )  [virtual]
 

Reimplemented in BRepTools_ShapeSet.


Field Documentation

Standard_Integer TopTools_ShapeSet::myFormatNb [private]
 

TopTools_LocationSet TopTools_ShapeSet::myLocations [private]
 

Handle_Message_ProgressIndicator TopTools_ShapeSet::myProgress [private]
 

TopTools_IndexedMapOfShape TopTools_ShapeSet::myShapes [private]
 


The documentation for this class was generated from the following file:
Generated on Mon Aug 25 13:23:13 2008 for OpenCASCADE by  doxygen 1.4.1