Eplan Platform API
Eplan.EplApi.EServices.Ged Namespace / Interaction Class
Members Example

In This Topic
    Interaction Class
    In This Topic
    Base class for special GED interaction.
    Inheritance Hierarchy
    Syntax
    public class Interaction 
    public ref class Interaction 
    Example
    Here is an example of an Interaction class: Starting an interaction is done by action 'XGedStartInteractionAction' :
    public class MyInteraction : Interaction
    {
        public override RequestCode OnStart(InteractionContext oContext)
        {
            return RequestCode.Point;
        }
    
        public override RequestCode OnPoint(Position oPosition)
        {
            m_arrPoints[m_iPoints] = oPosition.FinalPosition;
            ++m_iPoints;
            if (m_iPoints == 2)
            {
                return RequestCode.Success;
            }
            return RequestCode.Point;
        }
    
        public override void OnSuccess(InteractionContext oContext)
        {
            Line oLine = new Line();
            oLine.Create(Page, m_arrPoints[0], m_arrPoints[1]);
        }
    
        private int m_iPoints = 0;
        private PointD[] m_arrPoints = new PointD[2];
    }
    
    
    string strAction = "XGedStartInteractionAction";
    
    ActionManager oActionManager = new ActionManager();
    Action oAction = oActionManager.FindAction(strAction);
    if (oAction != null)
    {
        ActionCallingContext oContext = new ActionCallingContext();
        oContext.AddParameter("Name", "MyInteraction");
        oAction.Execute(oContext);
    }
    
    
    
    Public Constructors
     NameDescription
    Public ConstructorDefault constructor.  
    Top
    Public Properties
     NameDescription
    Public PropertyDescription of undo step for this interaction.  
    Public PropertyMouse cursor which will be used for next dragging operation.  
    Public PropertyInstallation space, the editor belongs to.  
    Public PropertyReturns true, if interaction should restart after stop.  
    Public PropertyReturns true, if interaction is used to insert one ore more placements on page.  
    Public PropertyReturns true, if special object placement mode is active.  
    Public PropertyIf true, then placement-filter is active.  
    Public PropertyReturns true, if function does not change the project database.  
    Public PropertyReturns true, if interaction is a helper interaction to select placements.  
    Public Propertycurrent mouse position  
    Public PropertyPage, the editor belongs to.  
    Public PropertyProject, the editor belongs to.  
    Public PropertyPrompt for command line.  
    Public PropertyPrompt for status line.  
    Public PropertyRoot placement to which the editor belongs.  
    Public Propertystart position of Interaction. The StartPosition is needed to calculate the current position while ortho mode is active or after input of length or angle the start position is automatically set after point input and before call of OnPoint after start of an interaction StartPosition is null  
    Public PropertyReturns true, if logical placements were changed.  
    Top
    Public Methods
     NameDescription
    Public MethodRemove Cursor-Representation.  
    Public MethodDestructor for deterministic finalization of Interaction object.  
    Public MethodReturns true, if interaction should be enabled in ribbon  
    Public MethodIs called after input of an angle by the user.  
    Public MethodIs called to calculate the cursor position.  
    Public MethodIs called to manipulate the position of the static CAD cursor.  
    Public MethodIs called after abort of interaction.  
    Public MethodIs called after keyboard inputs by the user.  
    Public MethodIs called on move of cursor by mouse or keys.  
    Public MethodIs called after start of a new interaction with same or higher priority. In this case the current interaction is deactivated until the new interaction stops.  
    Public MethodIs called to get drawable objects for the cursor representation.  
    Public MethodIs called after edged of a 3D mesh was selected by user.  
    Public MethodIs called after edge was found below the mouse pointer.  
    Public MethodIs called, when the placement below the mouse pointer changes as result of mouse movement.  
    Public MethodIs called after end of a dragging operation.  
    Public MethodIs called after face of a 3D mesh was selected by user.  
    Public MethodIs called after face was found below the mouse pointer.  
    Public MethodIs called by framework to determine if oObject should be included in selection or will be highlighted.  
    Public MethodIs called after special input operation has finished.  
    Public MethodIs called after input of length.  
    Public MethodIs called after Mouse leave the window.  
    Public MethodIs called after a point input by user via mouse or keyboard. That means, that the user has clicked into the CAD Window or opened the command line and input the coordinates of a point.  
    Public MethodIs called after stop of the current interaction and this interaction is reactivated.  
    Public MethodIs called after restart of the interaction.  
    Public MethodIs called on end of sub-interaction.  
    Public MethodIs called after object selection in the graphical editor by user.  
    Public MethodSpecial event has occurred. Usually caused by user input.  
    Public MethodIs called after start of interaction  
    Public MethodIs called after begin of a dragging operation.  
    Public MethodIs called before an interaction stops.  
    Public MethodIs called after successful input of all necessary data as reaction to the request code Success  
    Public MethodIs called after vertex of a 3D mesh was selected by user.  
    Public MethodIs called after vertex was found below the mouse pointer.  
    Public MethodActive Rubber-box cursor.  
    Public MethodActive Rubber-line cursor.  
    Public Methodcan be called to change selection. should only be used inside the OnSelect() method  
    Public MethodOverloaded. Sets Eplan.EplApi.DataModel.StorableObject, that will be temporary drawn as Cursor Representation.  
    Top
    See Also