Hoops Visualize HPS  version 2018-SP2
Hoops Visualize HPS 3D Rendering Engine
Looking for a senior C++ dev?
I'm looking for work. Hire me!
HPS::ShapeKit Class Reference

The ShapeKit class is a user space object. More...

#include <hps.h>

Inheritance diagram for HPS::ShapeKit:
Collaboration diagram for HPS::ShapeKit:

Public Member Functions

 ShapeKit ()
 The default constructor creates an empty ShapeKit object. More...
 
 ShapeKit (ShapeKit const &in_kit)
 The copy constructor creates a new ShapeKit object that contains the same settings as the source ShapeKit. More...
 
 ShapeKit (ShapeKit &&in_that)
 The move constructor creates a ShapeKit by transferring the underlying impl of the rvalue reference to this ShapeKit thereby avoiding a copy and allocation. More...
 
ShapeKitoperator= (ShapeKit &&in_that)
 The move assignment operator transfers the underlying impl of the rvalue reference to this ShapeKit thereby avoiding a copy. More...
 
virtual ~ShapeKit ()
 
HPS::Type ObjectType () const
 
void Set (ShapeKit const &in_kit)
 Copies the source ShapeKit into this ShapeKit. More...
 
void Show (ShapeKit &out_kit) const
 Copies this ShapeKit into the given ShapeKit. More...
 
ShapeKitoperator= (ShapeKit const &in_kit)
 Copies the source ShapeKit into this ShapeKit. More...
 
bool Empty () const
 Indicates whether this ShapeKit has any values set on it. More...
 
bool Equals (ShapeKit const &in_kit) const
 Check if the source ShapeKit is equivalent to this ShapeKit. More...
 
bool operator== (ShapeKit const &in_kit) const
 Check if the source ShapeKit is equivalent to this ShapeKit. More...
 
bool operator!= (ShapeKit const &in_kit) const
 Check if the source ShapeKit is not equivalent to this ShapeKit. More...
 
ShapeKitSetElements (ShapeElementArray const &in_def)
 Sets the elements for this ShapeKit. More...
 
ShapeKitSetElements (size_t in_count, ShapeElement const in_def [])
 Sets the elements for this ShapeKit. More...
 
ShapeKitSetElement (ShapeElement const &in_element)
 Set a single element for this ShapeKit. More...
 
ShapeKitUnsetElements ()
 Removes the elements for the shape. More...
 
ShapeKitUnsetEverything ()
 Removes all settings from this ShapeKit. More...
 
bool ShowElements (ShapeElementArray &out_def) const
 Shows the elements for this ShapeKit. More...
 
virtual HPS::Type Type () const
 This function returns the true type of the underlying object. More...
 
virtual void Reset ()
 Resets this object to its initial, uninitialized state. More...
 
bool HasType (HPS::Type in_mask) const
 This function indicates whether this Object has the given Type mask. More...
 
intptr_t GetClassID () const
 Returns a unique identifier that is shared by all objects of the same class. More...
 
intptr_t GetInstanceID () const
 Returns an identifier that can be used to identify which instance of a class an object is. More...
 

Static Public Member Functions

static HPS::ShapeKit GetDefault (Shape::Default in_default_shape)
 Creates a ShapeKit which contains the definition of the specified default shape. More...
 
template<typename T >
static intptr_t ClassID ()
 Unique identifier for this class. More...
 

Static Public Attributes

static const HPS::Type staticType = HPS::Type::ShapeKit
 

Detailed Description

The ShapeKit class is a user space object.

It is used for specifying all settings related to a ShapeDefinition.

Constructor & Destructor Documentation

◆ ShapeKit() [1/3]

HPS::ShapeKit::ShapeKit ( )

The default constructor creates an empty ShapeKit object.

◆ ShapeKit() [2/3]

HPS::ShapeKit::ShapeKit ( ShapeKit const &  in_kit)

The copy constructor creates a new ShapeKit object that contains the same settings as the source ShapeKit.

Parameters
in_kitThe source ShapeKit to copy.

◆ ShapeKit() [3/3]

HPS::ShapeKit::ShapeKit ( ShapeKit &&  in_that)

The move constructor creates a ShapeKit by transferring the underlying impl of the rvalue reference to this ShapeKit thereby avoiding a copy and allocation.

Parameters
in_thatAn rvalue reference to a ShapeKit to take the impl from.

◆ ~ShapeKit()

virtual HPS::ShapeKit::~ShapeKit ( )
virtual

Member Function Documentation

◆ ClassID()

template<typename T >
static intptr_t HPS::Object::ClassID ( )
inlinestaticinherited

Unique identifier for this class.

Note: this method uses construction of static objects. If used in a constructor, it should be used in the body not the initializer list.

◆ Empty()

bool HPS::ShapeKit::Empty ( ) const
virtual

Indicates whether this ShapeKit has any values set on it.

Returns
true if no values are set on this ShapeKit, false otherwise.

Reimplemented from HPS::Object.

◆ Equals()

bool HPS::ShapeKit::Equals ( ShapeKit const &  in_kit) const

Check if the source ShapeKit is equivalent to this ShapeKit.

Parameters
in_kitThe source ShapeKit to compare to this ShapeKit.
Returns
true if the objects are equivalent, false otherwise.

◆ GetClassID()

intptr_t HPS::Object::GetClassID ( ) const
inherited

Returns a unique identifier that is shared by all objects of the same class.

Returns
A unique value shared by all objects of the same class.

◆ GetDefault()

static HPS::ShapeKit HPS::ShapeKit::GetDefault ( Shape::Default  in_default_shape)
static

Creates a ShapeKit which contains the definition of the specified default shape.

Parameters
in_default_shapeThe default shape for which to get the corresponding ShapeKit.
Returns
A ShapeKit which contains the definition of the specified default shape.

◆ GetInstanceID()

intptr_t HPS::Object::GetInstanceID ( ) const
inherited

Returns an identifier that can be used to identify which instance of a class an object is.

Different keys and controls will return the same value if they are backed by the same database resource.

Returns
A value unique to an instance of an object and all objects that are backed by the same database resource.

◆ HasType()

bool HPS::Object::HasType ( HPS::Type  in_mask) const
inherited

This function indicates whether this Object has the given Type mask.

Parameters
in_maskThe Type mask to check against this Object.
Returns
true if this Object has the given Type mask, false otherwise.

◆ ObjectType()

HPS::Type HPS::ShapeKit::ObjectType ( ) const
inlinevirtual

Reimplemented from HPS::Kit.

Here is the call graph for this function:

◆ operator!=()

bool HPS::ShapeKit::operator!= ( ShapeKit const &  in_kit) const

Check if the source ShapeKit is not equivalent to this ShapeKit.

Parameters
in_kitThe source ShapeKit to compare to this ShapeKit.
Returns
true if the objects are not equivalent, false otherwise.

◆ operator=() [1/2]

ShapeKit& HPS::ShapeKit::operator= ( ShapeKit &&  in_that)

The move assignment operator transfers the underlying impl of the rvalue reference to this ShapeKit thereby avoiding a copy.

Parameters
in_thatAn rvalue reference to a ShapeKit to take the impl from.
Returns
A reference to this ShapeKit.

◆ operator=() [2/2]

ShapeKit& HPS::ShapeKit::operator= ( ShapeKit const &  in_kit)

Copies the source ShapeKit into this ShapeKit.

Parameters
in_kitThe source ShapeKit to copy.
Returns
A reference to this ShapeKit.

◆ operator==()

bool HPS::ShapeKit::operator== ( ShapeKit const &  in_kit) const

Check if the source ShapeKit is equivalent to this ShapeKit.

Parameters
in_kitThe source ShapeKit to compare to this ShapeKit.
Returns
true if the objects are equivalent, false otherwise.

◆ Reset()

◆ Set()

void HPS::ShapeKit::Set ( ShapeKit const &  in_kit)

Copies the source ShapeKit into this ShapeKit.

Parameters
in_kitThe source ShapeKit to copy.

◆ SetElement()

ShapeKit& HPS::ShapeKit::SetElement ( ShapeElement const &  in_element)

Set a single element for this ShapeKit.

This must be specified when defining a shape.

Parameters
in_elementA reference to the ShapeElement to set on this kit.
Returns
A reference to this ShapeKit.

◆ SetElements() [1/2]

ShapeKit& HPS::ShapeKit::SetElements ( ShapeElementArray const &  in_def)

Sets the elements for this ShapeKit.

This must be specified when defining a shape.

Parameters
in_defThe array of elements for the shape.
Returns
A reference to this ShapeKit.

◆ SetElements() [2/2]

ShapeKit& HPS::ShapeKit::SetElements ( size_t  in_count,
ShapeElement const  in_def[] 
)

Sets the elements for this ShapeKit.

This must be specified when defining a shape.

Parameters
in_countSize of the following array.
in_defThe array of elements for the shape.
Returns
A reference to this ShapeKit.

◆ Show()

void HPS::ShapeKit::Show ( ShapeKit out_kit) const

Copies this ShapeKit into the given ShapeKit.

Parameters
out_kitThe ShapeKit to populate with the contents of this ShapeKit.

◆ ShowElements()

bool HPS::ShapeKit::ShowElements ( ShapeElementArray out_def) const

Shows the elements for this ShapeKit.

Parameters
out_defThe elements for the shape.
Returns
true if elements were set, false otherwise.

◆ Type()

virtual HPS::Type HPS::Kit::Type ( ) const
inlinevirtualinherited

This function returns the true type of the underlying object.

This function is useful for finding the type of smart pointer objects that have been cast to more generic types.

Returns
The true type of the object in question.

Reimplemented from HPS::Object.

◆ UnsetElements()

ShapeKit& HPS::ShapeKit::UnsetElements ( )

Removes the elements for the shape.

Returns
A reference to this ShapeKit.

◆ UnsetEverything()

ShapeKit& HPS::ShapeKit::UnsetEverything ( )

Removes all settings from this ShapeKit.

Returns
A reference to this ShapeKit.

Member Data Documentation

◆ staticType

const HPS::Type HPS::ShapeKit::staticType = HPS::Type::ShapeKit
static

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