Skip to content

Commit f7484b5

Browse files
authored
update generated code (#1316)
1 parent afff511 commit f7484b5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+649
-191
lines changed

docs/source/_static/dpf_operators.html

Lines changed: 6 additions & 5 deletions
Large diffs are not rendered by default.

src/ansys/dpf/core/operators/mapping/solid_to_skin.py

Lines changed: 42 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,10 @@ class solid_to_skin(Operator):
1919
field : Field or FieldsContainer
2020
Field or fields container with only one field
2121
is expected
22-
mesh : MeshedRegion, optional
22+
mesh : MeshedRegion
2323
Skin mesh region expected
24+
solid_mesh : MeshedRegion, optional
25+
Solid mesh support (optional).
2426
2527
2628
Examples
@@ -35,25 +37,32 @@ class solid_to_skin(Operator):
3537
>>> op.inputs.field.connect(my_field)
3638
>>> my_mesh = dpf.MeshedRegion()
3739
>>> op.inputs.mesh.connect(my_mesh)
40+
>>> my_solid_mesh = dpf.MeshedRegion()
41+
>>> op.inputs.solid_mesh.connect(my_solid_mesh)
3842
3943
>>> # Instantiate operator and connect inputs in one line
4044
>>> op = dpf.operators.mapping.solid_to_skin(
4145
... field=my_field,
4246
... mesh=my_mesh,
47+
... solid_mesh=my_solid_mesh,
4348
... )
4449
4550
>>> # Get output data
4651
>>> result_field = op.outputs.field()
4752
"""
4853

49-
def __init__(self, field=None, mesh=None, config=None, server=None):
54+
def __init__(
55+
self, field=None, mesh=None, solid_mesh=None, config=None, server=None
56+
):
5057
super().__init__(name="solid_to_skin", config=config, server=server)
5158
self._inputs = InputsSolidToSkin(self)
5259
self._outputs = OutputsSolidToSkin(self)
5360
if field is not None:
5461
self.inputs.field.connect(field)
5562
if mesh is not None:
5663
self.inputs.mesh.connect(mesh)
64+
if solid_mesh is not None:
65+
self.inputs.solid_mesh.connect(solid_mesh)
5766

5867
@staticmethod
5968
def _spec():
@@ -72,9 +81,15 @@ def _spec():
7281
1: PinSpecification(
7382
name="mesh",
7483
type_names=["abstract_meshed_region"],
75-
optional=True,
84+
optional=False,
7685
document="""Skin mesh region expected""",
7786
),
87+
2: PinSpecification(
88+
name="solid_mesh",
89+
type_names=["abstract_meshed_region"],
90+
optional=True,
91+
document="""Solid mesh support (optional).""",
92+
),
7893
},
7994
map_output_pin_spec={
8095
0: PinSpecification(
@@ -136,6 +151,8 @@ class InputsSolidToSkin(_Inputs):
136151
>>> op.inputs.field.connect(my_field)
137152
>>> my_mesh = dpf.MeshedRegion()
138153
>>> op.inputs.mesh.connect(my_mesh)
154+
>>> my_solid_mesh = dpf.MeshedRegion()
155+
>>> op.inputs.solid_mesh.connect(my_solid_mesh)
139156
"""
140157

141158
def __init__(self, op: Operator):
@@ -144,6 +161,8 @@ def __init__(self, op: Operator):
144161
self._inputs.append(self._field)
145162
self._mesh = Input(solid_to_skin._spec().input_pin(1), 1, op, -1)
146163
self._inputs.append(self._mesh)
164+
self._solid_mesh = Input(solid_to_skin._spec().input_pin(2), 2, op, -1)
165+
self._inputs.append(self._solid_mesh)
147166

148167
@property
149168
def field(self):
@@ -186,6 +205,26 @@ def mesh(self):
186205
"""
187206
return self._mesh
188207

208+
@property
209+
def solid_mesh(self):
210+
"""Allows to connect solid_mesh input to the operator.
211+
212+
Solid mesh support (optional).
213+
214+
Parameters
215+
----------
216+
my_solid_mesh : MeshedRegion
217+
218+
Examples
219+
--------
220+
>>> from ansys.dpf import core as dpf
221+
>>> op = dpf.operators.mapping.solid_to_skin()
222+
>>> op.inputs.solid_mesh.connect(my_solid_mesh)
223+
>>> # or
224+
>>> op.inputs.solid_mesh(my_solid_mesh)
225+
"""
226+
return self._solid_mesh
227+
189228

190229
class OutputsSolidToSkin(_Outputs):
191230
"""Intermediate class used to get outputs from

src/ansys/dpf/core/operators/mapping/solid_to_skin_fc.py

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,10 @@ class solid_to_skin_fc(Operator):
1919
fields_container : FieldsContainer
2020
Field or fields container with only one field
2121
is expected
22-
mesh : MeshedRegion, optional
22+
mesh : MeshedRegion
2323
Skin mesh region expected
24+
solid_mesh : MeshedRegion, optional
25+
Solid mesh support (optional).
2426
2527
2628
Examples
@@ -35,25 +37,37 @@ class solid_to_skin_fc(Operator):
3537
>>> op.inputs.fields_container.connect(my_fields_container)
3638
>>> my_mesh = dpf.MeshedRegion()
3739
>>> op.inputs.mesh.connect(my_mesh)
40+
>>> my_solid_mesh = dpf.MeshedRegion()
41+
>>> op.inputs.solid_mesh.connect(my_solid_mesh)
3842
3943
>>> # Instantiate operator and connect inputs in one line
4044
>>> op = dpf.operators.mapping.solid_to_skin_fc(
4145
... fields_container=my_fields_container,
4246
... mesh=my_mesh,
47+
... solid_mesh=my_solid_mesh,
4348
... )
4449
4550
>>> # Get output data
4651
>>> result_fields_container = op.outputs.fields_container()
4752
"""
4853

49-
def __init__(self, fields_container=None, mesh=None, config=None, server=None):
54+
def __init__(
55+
self,
56+
fields_container=None,
57+
mesh=None,
58+
solid_mesh=None,
59+
config=None,
60+
server=None,
61+
):
5062
super().__init__(name="solid_to_skin_fc", config=config, server=server)
5163
self._inputs = InputsSolidToSkinFc(self)
5264
self._outputs = OutputsSolidToSkinFc(self)
5365
if fields_container is not None:
5466
self.inputs.fields_container.connect(fields_container)
5567
if mesh is not None:
5668
self.inputs.mesh.connect(mesh)
69+
if solid_mesh is not None:
70+
self.inputs.solid_mesh.connect(solid_mesh)
5771

5872
@staticmethod
5973
def _spec():
@@ -72,9 +86,15 @@ def _spec():
7286
1: PinSpecification(
7387
name="mesh",
7488
type_names=["abstract_meshed_region"],
75-
optional=True,
89+
optional=False,
7690
document="""Skin mesh region expected""",
7791
),
92+
2: PinSpecification(
93+
name="solid_mesh",
94+
type_names=["abstract_meshed_region"],
95+
optional=True,
96+
document="""Solid mesh support (optional).""",
97+
),
7898
},
7999
map_output_pin_spec={
80100
0: PinSpecification(
@@ -136,6 +156,8 @@ class InputsSolidToSkinFc(_Inputs):
136156
>>> op.inputs.fields_container.connect(my_fields_container)
137157
>>> my_mesh = dpf.MeshedRegion()
138158
>>> op.inputs.mesh.connect(my_mesh)
159+
>>> my_solid_mesh = dpf.MeshedRegion()
160+
>>> op.inputs.solid_mesh.connect(my_solid_mesh)
139161
"""
140162

141163
def __init__(self, op: Operator):
@@ -144,6 +166,8 @@ def __init__(self, op: Operator):
144166
self._inputs.append(self._fields_container)
145167
self._mesh = Input(solid_to_skin_fc._spec().input_pin(1), 1, op, -1)
146168
self._inputs.append(self._mesh)
169+
self._solid_mesh = Input(solid_to_skin_fc._spec().input_pin(2), 2, op, -1)
170+
self._inputs.append(self._solid_mesh)
147171

148172
@property
149173
def fields_container(self):
@@ -186,6 +210,26 @@ def mesh(self):
186210
"""
187211
return self._mesh
188212

213+
@property
214+
def solid_mesh(self):
215+
"""Allows to connect solid_mesh input to the operator.
216+
217+
Solid mesh support (optional).
218+
219+
Parameters
220+
----------
221+
my_solid_mesh : MeshedRegion
222+
223+
Examples
224+
--------
225+
>>> from ansys.dpf import core as dpf
226+
>>> op = dpf.operators.mapping.solid_to_skin_fc()
227+
>>> op.inputs.solid_mesh.connect(my_solid_mesh)
228+
>>> # or
229+
>>> op.inputs.solid_mesh(my_solid_mesh)
230+
"""
231+
return self._solid_mesh
232+
189233

190234
class OutputsSolidToSkinFc(_Outputs):
191235
"""Intermediate class used to get outputs from

src/ansys/dpf/core/operators/mesh/mesh_provider.py

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ class mesh_provider(Operator):
5151
read and a workflow will be bounded
5252
to the properties to be evaluated on
5353
demand, with 0 they are read (default
54-
is 0).
54+
is 0). - "all_available_properties"
55+
option set to 0 will return all
56+
possible properties
5557
5658
5759
Examples
@@ -181,7 +183,9 @@ def _spec():
181183
read and a workflow will be bounded
182184
to the properties to be evaluated on
183185
demand, with 0 they are read (default
184-
is 0).""",
186+
is 0). - "all_available_properties"
187+
option set to 0 will return all
188+
possible properties""",
185189
),
186190
},
187191
map_output_pin_spec={
@@ -398,7 +402,9 @@ def laziness(self):
398402
read and a workflow will be bounded
399403
to the properties to be evaluated on
400404
demand, with 0 they are read (default
401-
is 0).
405+
is 0). - "all_available_properties"
406+
option set to 0 will return all
407+
possible properties
402408
403409
Parameters
404410
----------

0 commit comments

Comments
 (0)