SHAPER 9.16.0
SketchAPI_Mirror.h
1// Copyright (C) 2014-2026 CEA, EDF
2//
3// This library is free software; you can redistribute it and/or
4// modify it under the terms of the GNU Lesser General Public
5// License as published by the Free Software Foundation; either
6// version 2.1 of the License, or (at your option) any later version.
7//
8// This library is distributed in the hope that it will be useful,
9// but WITHOUT ANY WARRANTY; without even the implied warranty of
10// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11// Lesser General Public License for more details.
12//
13// You should have received a copy of the GNU Lesser General Public
14// License along with this library; if not, write to the Free Software
15// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16//
17// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18//
19
20#ifndef SRC_SKETCHAPI_SKETCHAPI_MIRROR_H_
21#define SRC_SKETCHAPI_SKETCHAPI_MIRROR_H_
22
23//--------------------------------------------------------------------------------------
24#include "SketchAPI.h"
25#include "SketchAPI_SketchEntity.h"
26
27#include <list>
28
29#include <SketchPlugin_ConstraintMirror.h>
30
31#include <ModelHighAPI_Interface.h>
32#include <ModelHighAPI_Macro.h>
33//--------------------------------------------------------------------------------------
34class ModelAPI_Object;
36//--------------------------------------------------------------------------------------
42{
43public:
45 SKETCHAPI_EXPORT
46 explicit SketchAPI_Mirror(const std::shared_ptr<ModelAPI_Feature> & theFeature);
48 SKETCHAPI_EXPORT
49 SketchAPI_Mirror(const std::shared_ptr<ModelAPI_Feature> & theFeature,
50 const ModelHighAPI_RefAttr & theMirrorLine,
51 const std::list<std::shared_ptr<ModelAPI_Object> > & theObjects);
53 SKETCHAPI_EXPORT
54 virtual ~SketchAPI_Mirror();
55
65 )
66
67
68 SKETCHAPI_EXPORT
69 void setMirrorList(const std::list<std::shared_ptr<ModelAPI_Object> >& theObjects);
70
72 SKETCHAPI_EXPORT
73 std::list<std::shared_ptr<SketchAPI_SketchEntity> > mirrored() const;
74
76 virtual void dump(ModelHighAPI_Dumper& theDumper) const;
77};
78
80typedef std::shared_ptr<SketchAPI_Mirror> MirrorPtr;
81
82//--------------------------------------------------------------------------------------
83//--------------------------------------------------------------------------------------
84#endif /* SRC_SKETCHAPI_SKETCHAPI_MIRROR_H_ */
Attribute that contains reference to an attribute of a feature or reference to a feature (switchable)
Definition: ModelAPI_AttributeRefAttr.h:33
Attribute that contains list of references to features (located in the same document).
Definition: ModelAPI_AttributeRefList.h:33
Represents any object in the data model and in the object browser.
Definition: ModelAPI_Object.h:45
Dump engine for the model.
Definition: ModelHighAPI_Dumper.h:81
Base class for feature interfaces.
Definition: ModelHighAPI_Interface.h:46
Class for filling ModelAPI_AttributeRefAttr.
Definition: ModelHighAPI_RefAttr.h:41
Interface for Mirror feature.
Definition: SketchAPI_Mirror.h:42
void setMirrorList(const std::list< std::shared_ptr< ModelAPI_Object > > &theObjects)
Set list of original objects.
Definition: SketchAPI_Mirror.cpp:50
virtual ~SketchAPI_Mirror()
Destructor.
Definition: SketchAPI_Mirror.cpp:46
virtual std::shared_ptr< ModelAPI_AttributeRefAttr > mirrorLine() const
Mirror line.
Definition: SketchAPI_Mirror.h:65
virtual void dump(ModelHighAPI_Dumper &theDumper) const
Dump wrapped feature.
Definition: SketchAPI_Mirror.cpp:70
virtual std::shared_ptr< ModelAPI_AttributeRefList > mirroredObjects() const
Mirrored objects.
Definition: SketchAPI_Mirror.h:65
virtual std::shared_ptr< ModelAPI_AttributeRefList > mirrorList() const
Mirror list.
Definition: SketchAPI_Mirror.h:65
virtual std::shared_ptr< ModelAPI_AttributeRefList > referenceObjects() const
Reference objects.
Definition: SketchAPI_Mirror.h:65
std::list< std::shared_ptr< SketchAPI_SketchEntity > > mirrored() const
List of mirrored objects.
Definition: SketchAPI_Mirror.cpp:56
SketchAPI_Mirror(const std::shared_ptr< ModelAPI_Feature > &theFeature)
Constructor without values.
Definition: SketchAPI_Mirror.cpp:27
Base class for Sketch feature interfaces.
Definition: SketchAPI_SketchEntity.h:38
static const std::string & ID()
Mirror constraint kind.
Definition: SketchPlugin_ConstraintMirror.h:42
static const std::string & MIRROR_LIST_ID()
List of objects to be mirrored.
Definition: SketchPlugin_ConstraintMirror.h:55
static const std::string & ENTITY_A()
First entity for the constraint.
Definition: SketchPlugin_Constraint.h:58
static const std::string & ENTITY_C()
Third entity for the constraint.
Definition: SketchPlugin_Constraint.h:70
static const std::string & ENTITY_B()
Second entity for the constraint.
Definition: SketchPlugin_Constraint.h:64