update_potting_region#
- Layer.update_potting_region(request)#
Update one or more potting regions in a specific project.
Available Since: 2025R1
- Parameters:
- request: UpdatePottingRegionRequest
Contains all the information needed to update one or more potting regions per project.
- Returns:
- :
list
[SherlockCommonService_pb2.ReturnCode
]Return codes for each request.
- Return type:
list
[ReturnCode
]
Examples
>>> from ansys.sherlock.core.launcher import launch_sherlock >>> from ansys.sherlock.core.types.layer_types import PolygonalShape >>> from ansys.sherlock.core.types.layer_types import PottingRegionUpdateData >>> from ansys.sherlock.core.types.layer_types import PottingRegion >>> sherlock = launch_sherlock() >>> >>> update1 = PottingRegionUpdateData( >>> potting_region_id_to_update=potting_id, >>> potting_region=PottingRegionData( >>> cca_name=cca_name, >>> potting_id=potting_id, >>> potting_side=potting_side, >>> potting_material=potting_material, >>> potting_units=potting_units, >>> potting_thickness=potting_thickness, >>> potting_standoff=potting_standoff, >>> shape=PolygonalShape( >>> points=[(0, 1), (5, 1), (5, 5), (1, 5)], >>> rotation=45.0 >>> ) >>> ) >>> ) >>> update2 = PottingRegionUpdateData( >>> potting_region_id_to_update=potting_id, >>> potting_region=PottingRegionData( >>> cca_name=cca_name, >>> potting_id=potting_id, >>> potting_side=potting_side, >>> potting_material=potting_material, >>> potting_units=potting_units, >>> potting_thickness=potting_thickness, >>> potting_standoff=potting_standoff, >>> shape=PolygonalShape( >>> points=[(0, 1), (5, 1), (5, 5), (1, 5)], >>> rotation=0.0 >>> ) >>> ) >>> ) >>> example_request = UpdatePottingRegionRequest( >>> "project_name", >>> [ >>> update1, >>> update2 >>> ] >>> ) >>> return_codes = sherlock.layer.update_potting_region(example_request)