@@ -26,6 +26,8 @@ class rotate_in_cylindrical_cs(Operator):
2626 3-3 rotation matrix and origin coordinates
2727 must be set here to define a
2828 coordinate system.
29+ mesh : MeshedRegion, optional
30+ Mesh support of the input field
2931
3032
3133 Examples
@@ -40,25 +42,32 @@ class rotate_in_cylindrical_cs(Operator):
4042 >>> op.inputs.field.connect(my_field)
4143 >>> my_coordinate_system = dpf.Field()
4244 >>> op.inputs.coordinate_system.connect(my_coordinate_system)
45+ >>> my_mesh = dpf.MeshedRegion()
46+ >>> op.inputs.mesh.connect(my_mesh)
4347
4448 >>> # Instantiate operator and connect inputs in one line
4549 >>> op = dpf.operators.geo.rotate_in_cylindrical_cs(
4650 ... field=my_field,
4751 ... coordinate_system=my_coordinate_system,
52+ ... mesh=my_mesh,
4853 ... )
4954
5055 >>> # Get output data
51- >>> result_fields_container = op.outputs.fields_container ()
56+ >>> result_field = op.outputs.field ()
5257 """
5358
54- def __init__ (self , field = None , coordinate_system = None , config = None , server = None ):
59+ def __init__ (
60+ self , field = None , coordinate_system = None , mesh = None , config = None , server = None
61+ ):
5562 super ().__init__ (name = "transform_cylindricalCS" , config = config , server = server )
5663 self ._inputs = InputsRotateInCylindricalCs (self )
5764 self ._outputs = OutputsRotateInCylindricalCs (self )
5865 if field is not None :
5966 self .inputs .field .connect (field )
6067 if coordinate_system is not None :
6168 self .inputs .coordinate_system .connect (coordinate_system )
69+ if mesh is not None :
70+ self .inputs .mesh .connect (mesh )
6271
6372 @staticmethod
6473 def _spec ():
@@ -85,11 +94,17 @@ def _spec():
8594 must be set here to define a
8695 coordinate system.""" ,
8796 ),
97+ 2 : PinSpecification (
98+ name = "mesh" ,
99+ type_names = ["abstract_meshed_region" ],
100+ optional = True ,
101+ document = """Mesh support of the input field""" ,
102+ ),
88103 },
89104 map_output_pin_spec = {
90105 0 : PinSpecification (
91- name = "fields_container " ,
92- type_names = ["fields_container " ],
106+ name = "field " ,
107+ type_names = ["field " ],
93108 optional = False ,
94109 document = """""" ,
95110 ),
@@ -146,6 +161,8 @@ class InputsRotateInCylindricalCs(_Inputs):
146161 >>> op.inputs.field.connect(my_field)
147162 >>> my_coordinate_system = dpf.Field()
148163 >>> op.inputs.coordinate_system.connect(my_coordinate_system)
164+ >>> my_mesh = dpf.MeshedRegion()
165+ >>> op.inputs.mesh.connect(my_mesh)
149166 """
150167
151168 def __init__ (self , op : Operator ):
@@ -156,6 +173,8 @@ def __init__(self, op: Operator):
156173 rotate_in_cylindrical_cs ._spec ().input_pin (1 ), 1 , op , - 1
157174 )
158175 self ._inputs .append (self ._coordinate_system )
176+ self ._mesh = Input (rotate_in_cylindrical_cs ._spec ().input_pin (2 ), 2 , op , - 1 )
177+ self ._inputs .append (self ._mesh )
159178
160179 @property
161180 def field (self ):
@@ -200,6 +219,26 @@ def coordinate_system(self):
200219 """
201220 return self ._coordinate_system
202221
222+ @property
223+ def mesh (self ):
224+ """Allows to connect mesh input to the operator.
225+
226+ Mesh support of the input field
227+
228+ Parameters
229+ ----------
230+ my_mesh : MeshedRegion
231+
232+ Examples
233+ --------
234+ >>> from ansys.dpf import core as dpf
235+ >>> op = dpf.operators.geo.rotate_in_cylindrical_cs()
236+ >>> op.inputs.mesh.connect(my_mesh)
237+ >>> # or
238+ >>> op.inputs.mesh(my_mesh)
239+ """
240+ return self ._mesh
241+
203242
204243class OutputsRotateInCylindricalCs (_Outputs ):
205244 """Intermediate class used to get outputs from
@@ -210,29 +249,27 @@ class OutputsRotateInCylindricalCs(_Outputs):
210249 >>> from ansys.dpf import core as dpf
211250 >>> op = dpf.operators.geo.rotate_in_cylindrical_cs()
212251 >>> # Connect inputs : op.inputs. ...
213- >>> result_fields_container = op.outputs.fields_container ()
252+ >>> result_field = op.outputs.field ()
214253 """
215254
216255 def __init__ (self , op : Operator ):
217256 super ().__init__ (rotate_in_cylindrical_cs ._spec ().outputs , op )
218- self ._fields_container = Output (
219- rotate_in_cylindrical_cs ._spec ().output_pin (0 ), 0 , op
220- )
221- self ._outputs .append (self ._fields_container )
257+ self ._field = Output (rotate_in_cylindrical_cs ._spec ().output_pin (0 ), 0 , op )
258+ self ._outputs .append (self ._field )
222259
223260 @property
224- def fields_container (self ):
225- """Allows to get fields_container output of the operator
261+ def field (self ):
262+ """Allows to get field output of the operator
226263
227264 Returns
228265 ----------
229- my_fields_container : FieldsContainer
266+ my_field : Field
230267
231268 Examples
232269 --------
233270 >>> from ansys.dpf import core as dpf
234271 >>> op = dpf.operators.geo.rotate_in_cylindrical_cs()
235272 >>> # Connect inputs : op.inputs. ...
236- >>> result_fields_container = op.outputs.fields_container ()
273+ >>> result_field = op.outputs.field ()
237274 """ # noqa: E501
238- return self ._fields_container
275+ return self ._field
0 commit comments