# Visualization
TKV2d
AIS2D

# AIS2D_InteractiveObject Class Reference

Class Interactive Object defines a class of objects
with display and selection services.
Using visualization and selection machanisms,
interactive objects are used to display datum, curves,
shapes, markers, dimensions, etc. Interactive objects
also provide links to the interactive context.
.

`#include <AIS2D_InteractiveObject.hxx>`

Inheritance diagram for AIS2D_InteractiveObject:

[legend]

## Public Member Functions

Standard_EXPORT | AIS2D_InteractiveObject ()
| Initialize the Interactive Object .
Handle_Prs2d_Drawer | Attributes () const
| Returns the attributes settings .
virtual Standard_EXPORT void | SetAttributes (const Handle(Prs2d_Drawer)&aDrawer)
| Initializes the drawing tool <adrawer> .
virtual Standard_EXPORT void | UnsetAttributes ()
| Clears settings provided by the drawing tool <adrawer> .
Standard_EXPORT void | SetAspect (const Handle(Prs2d_AspectRoot)&anAspect)
| Sets the attributes from Aspect <anaspect> to all primitives appropriate this Aspect. .
Standard_EXPORT void | SetAspect (const Handle(Prs2d_AspectRoot)&anAspect, const Handle(Graphic2d_Primitive)&aPrimitive)
| Sets the attributes from Aspect <anaspect> to primitive <aprimitive> Method works only for objects are linked with InteractiveContext .
Standard_EXPORT Handle_Prs2d_AspectRoot | GetAspect (const Handle(Graphic2d_Primitive)&aPrimitive) const
| Returns Aspect for primitive <aprimitive> Method works only for objects are linked with InteractiveContext .
Standard_EXPORT Standard_Boolean | HasAspect (const Handle(Graphic2d_Primitive)&aPrimitive) const
| Returns true if primitive <aprimitive> is linked with an aspect .
Standard_EXPORT Standard_Boolean | HasInteractiveContext () const
| Indicates whether the Interactive Object has a pointer to an interactive context. .
Standard_EXPORT Handle_AIS2D_InteractiveContext | GetContext () const
| Returns the context pointer to the interactive context. .
virtual Standard_EXPORT void | SetContext (const Handle(AIS2D_InteractiveContext)&aCntx)
| Places a link to <acntx>. The drawer of AIS2D_InteractiveObject is connected to the Default Drawer Of <acntx>. That Means that this method has to be redefined if computations depend on drawer values. .
Standard_Integer | DisplayMode () const
| Indicates the display mode of the Interactive Object .
Standard_Boolean | HasDisplayMode () const
| Returns True if the Interactive Object has a display mode setting. Otherwise, it is displayed in Neutral Point. .
void | SetDisplayMode (const Standard_Integer aMode)
| Allows to provide a setting <amode> for an Interactive Object's display mode. .
void | UnsetDisplayMode ()
| Removes display mode settings from the Interactive object .
virtual Standard_Integer | DefaultDisplayMode () const
| Returns the default display mode. This method is to be implemented when the main mode is not mode 0. .
virtual Standard_Boolean | AcceptDisplayMode (const Standard_Integer aMode) const
| Returns true if the class of objects accepts the display mode <amode> .
AIS2D_TypeOfDetection | HighlightMode () const
| Returns the setting for highlight mode. .
Standard_Boolean | HasHighlightMode () const
| Returns true if the Interactive Object is in highlight mode .
void | SetHighlightMode (const AIS2D_TypeOfDetection aMode)
| Allows to provide settings for highlight mode. .
void | UnsetHighlightMode ()
| Removes settings for highlight mode .
virtual AIS2D_TypeOfDetection | DefaultHighlightMode () const
| Returns the default highlight mode .
Standard_Integer | SelectionMode () const
| Indicates the selection mode of the Interactive Object .
Standard_Boolean | HasSelectionMode () const
| Allows you to change the selection mode of an Interactive Object .
void | SetSelectionMode (const Standard_Integer aMode)
| Allows to provide a setting <amode> for an Interactive Object's selection mode. .
void | UnsetSelectionMode ()
| Removes settings for selection mode .
virtual Standard_Integer | DefaultSelectionMode () const
| Returns the default selection mode .
Standard_Integer | State () const
void | SetState (const Standard_Integer aState)
Standard_EXPORT void | SelectPrimitive (const Standard_Integer anIndex, const Standard_Boolean append)
| Selects primitive with index( TOD_PRIMITIVE mode only ) .
virtual Standard_EXPORT void | Save (Aspect_FStream &aFStream) const
virtual Standard_EXPORT void | Retrieve (Aspect_IFStream &anIFStream) const
Standard_EXPORT const | Handle (Standard_Type)&DynamicType() const

## Protected Attributes

Handle_Prs2d_Drawer | myDrawer
AIS2D_TypeOfDetection | myHighlightMode

## Private Member Functions

Standard_EXPORT Standard_Boolean | PrimitiveExist (const Prs2d_AspectName aName) const
Standard_EXPORT void | AddDetectPrim (const Handle(Graphic2d_Primitive)&aPrim, const Standard_Integer anInd)
Standard_EXPORT void | AddSelectPrim (const Handle(Graphic2d_Primitive)&aPrim, const Standard_Integer anInd)
Standard_EXPORT void | RemoveSelectPrim (const Handle(Graphic2d_Primitive)&aPrim, const Standard_Integer anInd)
Standard_EXPORT void | SetSelSeqPrim (const Handle(AIS2D_HSequenceOfPrimArchit)&aSeq)
Standard_EXPORT void | ClearSeqDetPrim ()
Standard_EXPORT void | ClearSeqSelPrim ()
Standard_EXPORT Handle_AIS2D_HSequenceOfPrimArchit | GetDetectSeqPrim () const
Standard_EXPORT Handle_AIS2D_HSequenceOfPrimArchit | GetSelectedSeqPrim () const

## Private Attributes

Handle_AIS2D_InteractiveContext | myICTX
Standard_Integer | myDisplayMode
Standard_Integer | mySelectionMode
AIS2D_DataMapOfPrimAspects | myAspects
Standard_Integer | myState
Handle_AIS2D_HSequenceOfPrimArchit | myDetectedPrimSeq
Handle_AIS2D_HSequenceOfPrimArchit | mySelectedPrimSeq

## Constructor & Destructor Documentation

Standard_EXPORT AIS2D_InteractiveObject::AIS2D_InteractiveObject | ( |  | ) |

## Member Function Documentation

Standard_Boolean AIS2D_InteractiveObject::AcceptDisplayMode | ( | const Standard_Integer | aMode | ) | const`[inline, virtual]`

Standard_EXPORT void AIS2D_InteractiveObject::AddDetectPrim | ( | const Handle(Graphic2d_Primitive)& | aPrim,
|  | const Standard_Integer | anInd
| ) | `[private]`

Standard_EXPORT void AIS2D_InteractiveObject::AddSelectPrim | ( | const Handle(Graphic2d_Primitive)& | aPrim,
|  | const Standard_Integer | anInd
| ) | `[private]`

Handle_Prs2d_Drawer AIS2D_InteractiveObject::Attributes | ( |  | ) | const

Standard_EXPORT void AIS2D_InteractiveObject::ClearSeqDetPrim | ( |  | ) | `[private]`

Standard_EXPORT void AIS2D_InteractiveObject::ClearSeqSelPrim | ( |  | ) | `[private]`

Standard_Integer AIS2D_InteractiveObject::DefaultDisplayMode | ( |  | ) | const`[inline, virtual]`

AIS2D_TypeOfDetection AIS2D_InteractiveObject::DefaultHighlightMode | ( |  | ) | const`[inline, virtual]`

Standard_Integer AIS2D_InteractiveObject::DefaultSelectionMode | ( |  | ) | const`[inline, virtual]`

Standard_Integer AIS2D_InteractiveObject::DisplayMode | ( |  | ) | const`[inline]`

Standard_EXPORT Handle_Prs2d_AspectRoot AIS2D_InteractiveObject::GetAspect | ( | const Handle(Graphic2d_Primitive)& | aPrimitive | ) | const

Standard_EXPORT Handle_AIS2D_InteractiveContext AIS2D_InteractiveObject::GetContext | ( |  | ) | const

Standard_EXPORT Handle_AIS2D_HSequenceOfPrimArchit AIS2D_InteractiveObject::GetDetectSeqPrim | ( |  | ) | const`[private]`

Standard_EXPORT Handle_AIS2D_HSequenceOfPrimArchit AIS2D_InteractiveObject::GetSelectedSeqPrim | ( |  | ) | const`[private]`

Standard_EXPORT const AIS2D_InteractiveObject::Handle | ( | Standard_Type |  | ) | const

| Reimplemented from Graphic2d_GraphicObject. Reimplemented in AIS2D_ProjShape.

Standard_EXPORT Standard_Boolean AIS2D_InteractiveObject::HasAspect | ( | const Handle(Graphic2d_Primitive)& | aPrimitive | ) | const

Standard_Boolean AIS2D_InteractiveObject::HasDisplayMode | ( |  | ) | const`[inline]`

Standard_Boolean AIS2D_InteractiveObject::HasHighlightMode | ( |  | ) | const`[inline]`

Standard_EXPORT Standard_Boolean AIS2D_InteractiveObject::HasInteractiveContext | ( |  | ) | const

Standard_Boolean AIS2D_InteractiveObject::HasSelectionMode | ( |  | ) | const`[inline]`

AIS2D_TypeOfDetection AIS2D_InteractiveObject::HighlightMode | ( |  | ) | const`[inline]`

Standard_EXPORT Standard_Boolean AIS2D_InteractiveObject::PrimitiveExist | ( | const Prs2d_AspectName | aName | ) | const`[private]`

Standard_EXPORT void AIS2D_InteractiveObject::RemoveSelectPrim | ( | const Handle(Graphic2d_Primitive)& | aPrim,
|  | const Standard_Integer | anInd
| ) | `[private]`

virtual Standard_EXPORT void AIS2D_InteractiveObject::Retrieve | ( | Aspect_IFStream & | anIFStream | ) | const`[virtual]`

virtual Standard_EXPORT void AIS2D_InteractiveObject::Save | ( | Aspect_FStream & | aFStream | ) | const`[virtual]`

Standard_Integer AIS2D_InteractiveObject::SelectionMode | ( |  | ) | const`[inline]`

Standard_EXPORT void AIS2D_InteractiveObject::SelectPrimitive | ( | const Standard_Integer | anIndex,
|  | const Standard_Boolean | append
| ) |

Standard_EXPORT void AIS2D_InteractiveObject::SetAspect | ( | const Handle(Prs2d_AspectRoot)& | anAspect,
|  | const Handle(Graphic2d_Primitive)& | aPrimitive
| ) |

Standard_EXPORT void AIS2D_InteractiveObject::SetAspect | ( | const Handle(Prs2d_AspectRoot)& | anAspect | ) |

virtual Standard_EXPORT void AIS2D_InteractiveObject::SetAttributes | ( | const Handle(Prs2d_Drawer)& | aDrawer | ) | `[virtual]`

virtual Standard_EXPORT void AIS2D_InteractiveObject::SetContext | ( | const Handle(AIS2D_InteractiveContext)& | aCntx | ) | `[virtual]`

void AIS2D_InteractiveObject::SetDisplayMode | ( | const Standard_Integer | aMode | ) | `[inline]`

void AIS2D_InteractiveObject::SetHighlightMode | ( | const AIS2D_TypeOfDetection | aMode | ) | `[inline]`

void AIS2D_InteractiveObject::SetSelectionMode | ( | const Standard_Integer | aMode | ) | `[inline]`

Standard_EXPORT void AIS2D_InteractiveObject::SetSelSeqPrim | ( | const Handle(AIS2D_HSequenceOfPrimArchit)& | aSeq | ) | `[private]`

void AIS2D_InteractiveObject::SetState | ( | const Standard_Integer | aState | ) | `[inline]`

Standard_Integer AIS2D_InteractiveObject::State | ( |  | ) | const`[inline]`

virtual Standard_EXPORT void AIS2D_InteractiveObject::UnsetAttributes | ( |  | ) | `[virtual]`

void AIS2D_InteractiveObject::UnsetDisplayMode | ( |  | ) | `[inline]`

void AIS2D_InteractiveObject::UnsetHighlightMode | ( |  | ) | `[inline]`

void AIS2D_InteractiveObject::UnsetSelectionMode | ( |  | ) | `[inline]`

## Field Documentation

AIS2D_DataMapOfPrimAspects AIS2D_InteractiveObject::myAspects `[private]`

Handle_AIS2D_HSequenceOfPrimArchit AIS2D_InteractiveObject::myDetectedPrimSeq `[private]`

Standard_Integer AIS2D_InteractiveObject::myDisplayMode `[private]`

Handle_Prs2d_Drawer AIS2D_InteractiveObject::myDrawer `[protected]`

AIS2D_TypeOfDetection AIS2D_InteractiveObject::myHighlightMode `[protected]`

Handle_AIS2D_InteractiveContext AIS2D_InteractiveObject::myICTX `[private]`

Handle_AIS2D_HSequenceOfPrimArchit AIS2D_InteractiveObject::mySelectedPrimSeq `[private]`

Standard_Integer AIS2D_InteractiveObject::mySelectionMode `[private]`

Standard_Integer AIS2D_InteractiveObject::myState `[private]`

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

- AIS2D_InteractiveObject.hxx
- AIS2D_InteractiveObject.lxx