IGraphicHierarchy

IGraphicHierarchy is an abstract base class that defines a hierarchy protocol. This is the only class that has the protocol for creating an iterator which allows hierarchies to traverse themselves. All clients must define their own set of hierarchies using this abstract base class as its parent class.


IGraphicHierarchy - Member Functions and Data by Group

Constructors & Destructor

This group contains the constructors and destructor that create and destroy objects of class IGraphicHierarchy.


[view class]
~IGraphicHierarchy
public:
virtual ~IGraphicHierarchy()
Destroy's the IGraphicHierarchy object.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
IGraphicHierarchy


Overload 1
Constructs an IGraphicHierarchy from a graph bundle.
protected:
IGraphicHierarchy(IGrafBundle* adoptBundle)

adoptBundle
The graph bundle.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Overload 2
Protected copy constructor.
protected:
IGraphicHierarchy(const IGraphicHierarchy&)

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Overload 3
Protected default constructor.
protected:
IGraphicHierarchy()

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Assignment Operator

Use the operator in this group to assign the given object to the target one.


[view class]
operator =
protected:
IGraphicHierarchy& operator =( const IGraphicHierarchy& source )
Assignment Operator.

source
The object to be copied from.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Creating an Iterator

Use the function in this group to create an IGraphicHierarchy iterator.


[view class]
createIterator
public:
virtual IGraphicIterator* createIterator() const = 0
Creates a IGraphicIterator which iterates through the first level of the hierarchy.

None

Return
A graphic iterator for the first level of this hierarchy.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Obtaining Bounding Information

Use the functions in this group to get the objects bounding rectangle.


[view class]
geometricBounds
public:
virtual IGRect2D geometricBounds() const = 0
Gets the bounding rectangle of the IGraphicHierarchy's geometry, without considering any area added by the bundle.

None

Return
Returns the bounding rectangle, which is the smallest axis-aligned rectangle that encloses the graphic hierarchy's geometry.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
looseFitBounds
public:
virtual IGRect2D looseFitBounds( const IGrafPort* = 0 ) const = 0
Returns the entire graphic's bounding rectangle, taking into account the bundle information.

IGrafPort
The graphics port used for accessing hierarchical bundles.

Return
The bounding rectangle, which is the smallest axis-aligned rectangle that encloses the entire graphic, including any area added by the pen.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Rendering the Graphic

Use the function in this group to draw the object to the port.


[view class]
draw
public:
virtual void draw(IGrafPort&) const = 0
Draws the IGraphicHierarchy to the specific IGrafPort.

IGrafPort&
The port to which drawing should go. The port in turn invokes rendering on a particular IGrafDevice

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Streaming an Object In and Out

Use the functions in this group to stream the object in and out.


[view class]
readFromStream
protected:
virtual void readFromStream(IDataStream& toWhere)
Reads the object in from the specified stream.

fromStream
The stream from which the object is read in.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


[view class]
writeToStream
protected:
virtual void writeToStream(IDataStream& toWhere) const
Writes the object out to the specified stream.

toWhere
The stream to which the object is written out.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Testing an IGraphicHierarchy and an IMDrawable Object for Equality

Use the functions in this group to test the IGraphicHierarchy with an IMDrawable object for equality.


[view class]
operator ==
public:
virtual bool operator ==(const IMDrawable&) const
Tests the IGraphicHierarchy and the IMDrawable for equality. The base class only tests whether the two bundles have equal contents.

IMDrawable
A constant reference to the IMDrawable to be compared with this one.

Return
True if this IGraphicHierarchy and the argument have equal bundles.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


Transforming the IGraphicHierarchy

Use the function in this group to transform the shape of the object or change its position.


[view class]
transformBy
public:
virtual void transformBy(const IGrafMatrix&) = 0
Transforms the IGraphicHierarchy's shape and position by applying the specified transformation matrix.

IGrafMatrix
A constant reference to the transformation matrix by which the graphic hierarchy's points are multiplied.

Supported Platforms

Windows OS/2 AIX
Yes Yes Yes


IGraphicHierarchy - Inherited Member Functions and Data

Inherited Public Functions

IMDrawable
IMGraphic
IMStreamable

Inherited Public Data

Inherited Protected Functions

IMDrawable
IMGraphic
IMStreamable

Inherited Protected Data