IJoint
- IJoint encapsulates common functionality for frame Joints. Joints will only be created by the pen at points of Co (C - zero continuity).
Typically these include a Polyline, Polygon etc. A special pen can, however, change this default
behavior. The start and end points have caps attached.
In order to avoid polymorphic behavior for this class, the miterLimit has been added to
this class
IJoint - Member Functions and Data by Group
Constructors & Destructor
Use the constructors in this group to create objects of class IJoint.
- ~IJoint
public:
~IJoint()
Destructs an object of class IJoint.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
- IJoint
- Constructs an object of class IJoint.
Overload 1
- Copy constructor.
public:
IJoint(const IJoint&)
- const IJoint&
- The joint to copy from.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
Overload 2
public:
IJoint( EJointType = kMiterLimit,
GCoordinate miterLimit = 1.0 )
- Constructor with parameters.
MiterLimit is 1.0 for all joints even though it is only applicable to the
MiterLimit joint. For all other joints, the miter limit of 1.0 will be
returned by the memberfunction miterLimit().
This has been added in the class to avoid the use of polymorphism for simple
classes such as Joints.
- EJointType = kMiterLimit
- The type of joint.
- miterLimit = 1.0
- The limit for miter joint.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
Assignment Operator
Use the operator in this group to assign the given IJoint object to the target one.
- operator =
public:
IJoint& operator =(const IJoint& source)
- Assignment operator.
- source
- The joint to copy from.
- Return
- A non-const reference to the left-hand side object.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
Comparing Two IJoint Objects for Equality or Inequality
Use the operators in this group to test two IJoint objects for equality or inequality.
- operator !=
public:
virtual bool operator !=(const IJoint&) const
- Tests two IJoint objects for inequality.
- IJoint
- A constant reference to the IJoint to be compared with.
- Return
- True if the two IJoint objects have diferent type or the limits are different for miter joints.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
- operator ==
public:
virtual bool operator ==(const IJoint&) const
- Tests two IJoint objects for equality.
- IJoint
- A constant reference to the IJoint to be compared with.
- Return
- True if the two IJoint objects are the same type and have the same limits for miter joints.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
Getting and Setting the Joint Type and Limit
Use the functions in this group to get and set the type and limit of the joint.
- jointType
public:
EJointType jointType() const
- Returns the type of the joint.
- Return
- The type of the joint.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
- miterLimit
public:
GCoordinate miterLimit() const
- Returns the limit of the joint.
- Return
- The limit of the joint.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
- setJointType
public:
void
setJointType( EJointType type,
GCoordinate mLimit = 1.0 )
- Sets the type and limit of the joint.
- type
- The type of the joint.
- mLimit
- The limit of the joint. The default value is 1.0.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
Streaming an Object In and Out
Use the functions in this group to read the object in from the specified stream or write it out to it.
- readFromStream
protected:
virtual void readFromStream(IDataStream& toWhere)
- Reads the IJoint object in from the specified stream.
- fromWhere
- The stream that the object is read in from.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
- writeToStream
protected:
virtual void writeToStream(IDataStream& toWhere) const
- Writes the IJoint object out to the specified stream.
- toWhere
- The stream that the object is written out to,
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
IJoint - Enumerations
- EJointType
enum EJointType { kMiterLimit,
kBevel,
kRound,
kUnknown }
- Describes the type of joint. An RTTI acceleration for known joint types.
- Supported Platforms
Windows |
OS/2 |
AIX |
Yes |
Yes |
Yes |
IJoint - Inherited Member Functions and Data
Inherited Public Functions
- IMStreamable
-
Inherited Public Data
Inherited Protected Functions
- IMStreamable
-
IMStreamable(const IMStreamable& other)
IMStreamable()
virtual void readFromStream(IDataStream& fromwhere) = 0
virtual void writeToStream(IDataStream& towhere) const = 0
Inherited Protected Data