1 // Created on : Sat May 02 12:41:15 2020
2 // Created by: Irina KRYLOVA
3 // Generator:	Express (EXPRESS -> CASCADE/XSTEP Translator) V3.0
4 // Copyright (c) Open CASCADE 2020
5 //
6 // This file is part of Open CASCADE Technology software library.
7 //
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
13 //
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
16 
17 #include <StepKinematics_GearPairWithRange.hxx>
18 
IMPLEMENT_STANDARD_RTTIEXT(StepKinematics_GearPairWithRange,StepKinematics_GearPair)19 IMPLEMENT_STANDARD_RTTIEXT(StepKinematics_GearPairWithRange, StepKinematics_GearPair)
20 
21 //=======================================================================
22 //function : StepKinematics_GearPairWithRange
23 //purpose  :
24 //=======================================================================
25 StepKinematics_GearPairWithRange::StepKinematics_GearPairWithRange ()
26 {
27   defLowerLimitActualRotation1 = Standard_False;
28   defUpperLimitActualRotation1 = Standard_False;
29 }
30 
31 //=======================================================================
32 //function : Init
33 //purpose  :
34 //=======================================================================
Init(const Handle (TCollection_HAsciiString)& theRepresentationItem_Name,const Handle (TCollection_HAsciiString)& theItemDefinedTransformation_Name,const Standard_Boolean hasItemDefinedTransformation_Description,const Handle (TCollection_HAsciiString)& theItemDefinedTransformation_Description,const Handle (StepRepr_RepresentationItem)& theItemDefinedTransformation_TransformItem1,const Handle (StepRepr_RepresentationItem)& theItemDefinedTransformation_TransformItem2,const Handle (StepKinematics_KinematicJoint)& theKinematicPair_Joint,const Standard_Real theGearPair_RadiusFirstLink,const Standard_Real theGearPair_RadiusSecondLink,const Standard_Real theGearPair_Bevel,const Standard_Real theGearPair_HelicalAngle,const Standard_Real theGearPair_GearRatio,const Standard_Boolean hasLowerLimitActualRotation1,const Standard_Real theLowerLimitActualRotation1,const Standard_Boolean hasUpperLimitActualRotation1,const Standard_Real theUpperLimitActualRotation1)35 void StepKinematics_GearPairWithRange::Init (const Handle(TCollection_HAsciiString)& theRepresentationItem_Name,
36                                              const Handle(TCollection_HAsciiString)& theItemDefinedTransformation_Name,
37                                              const Standard_Boolean hasItemDefinedTransformation_Description,
38                                              const Handle(TCollection_HAsciiString)& theItemDefinedTransformation_Description,
39                                              const Handle(StepRepr_RepresentationItem)& theItemDefinedTransformation_TransformItem1,
40                                              const Handle(StepRepr_RepresentationItem)& theItemDefinedTransformation_TransformItem2,
41                                              const Handle(StepKinematics_KinematicJoint)& theKinematicPair_Joint,
42                                              const Standard_Real theGearPair_RadiusFirstLink,
43                                              const Standard_Real theGearPair_RadiusSecondLink,
44                                              const Standard_Real theGearPair_Bevel,
45                                              const Standard_Real theGearPair_HelicalAngle,
46                                              const Standard_Real theGearPair_GearRatio,
47                                              const Standard_Boolean hasLowerLimitActualRotation1,
48                                              const Standard_Real theLowerLimitActualRotation1,
49                                              const Standard_Boolean hasUpperLimitActualRotation1,
50                                              const Standard_Real theUpperLimitActualRotation1)
51 {
52   StepKinematics_GearPair::Init(theRepresentationItem_Name,
53                                 theItemDefinedTransformation_Name,
54                                 hasItemDefinedTransformation_Description,
55                                 theItemDefinedTransformation_Description,
56                                 theItemDefinedTransformation_TransformItem1,
57                                 theItemDefinedTransformation_TransformItem2,
58                                 theKinematicPair_Joint,
59                                 theGearPair_RadiusFirstLink,
60                                 theGearPair_RadiusSecondLink,
61                                 theGearPair_Bevel,
62                                 theGearPair_HelicalAngle,
63                                 theGearPair_GearRatio);
64 
65   defLowerLimitActualRotation1 = hasLowerLimitActualRotation1;
66   if (defLowerLimitActualRotation1) {
67     myLowerLimitActualRotation1 = theLowerLimitActualRotation1;
68   }
69   else myLowerLimitActualRotation1 = 0;
70 
71   defUpperLimitActualRotation1 = hasUpperLimitActualRotation1;
72   if (defUpperLimitActualRotation1) {
73     myUpperLimitActualRotation1 = theUpperLimitActualRotation1;
74   }
75   else myUpperLimitActualRotation1 = 0;
76 }
77 
78 //=======================================================================
79 //function : LowerLimitActualRotation1
80 //purpose  :
81 //=======================================================================
LowerLimitActualRotation1() const82 Standard_Real StepKinematics_GearPairWithRange::LowerLimitActualRotation1 () const
83 {
84   return myLowerLimitActualRotation1;
85 }
86 
87 //=======================================================================
88 //function : SetLowerLimitActualRotation1
89 //purpose  :
90 //=======================================================================
SetLowerLimitActualRotation1(const Standard_Real theLowerLimitActualRotation1)91 void StepKinematics_GearPairWithRange::SetLowerLimitActualRotation1 (const Standard_Real theLowerLimitActualRotation1)
92 {
93   myLowerLimitActualRotation1 = theLowerLimitActualRotation1;
94 }
95 
96 //=======================================================================
97 //function : HasLowerLimitActualRotation1
98 //purpose  :
99 //=======================================================================
HasLowerLimitActualRotation1() const100 Standard_Boolean StepKinematics_GearPairWithRange::HasLowerLimitActualRotation1 () const
101 {
102   return defLowerLimitActualRotation1;
103 }
104 
105 //=======================================================================
106 //function : UpperLimitActualRotation1
107 //purpose  :
108 //=======================================================================
UpperLimitActualRotation1() const109 Standard_Real StepKinematics_GearPairWithRange::UpperLimitActualRotation1 () const
110 {
111   return myUpperLimitActualRotation1;
112 }
113 
114 //=======================================================================
115 //function : SetUpperLimitActualRotation1
116 //purpose  :
117 //=======================================================================
SetUpperLimitActualRotation1(const Standard_Real theUpperLimitActualRotation1)118 void StepKinematics_GearPairWithRange::SetUpperLimitActualRotation1 (const Standard_Real theUpperLimitActualRotation1)
119 {
120   myUpperLimitActualRotation1 = theUpperLimitActualRotation1;
121 }
122 
123 //=======================================================================
124 //function : HasUpperLimitActualRotation1
125 //purpose  :
126 //=======================================================================
HasUpperLimitActualRotation1() const127 Standard_Boolean StepKinematics_GearPairWithRange::HasUpperLimitActualRotation1 () const
128 {
129   return defUpperLimitActualRotation1;
130 }
131