update_component_failure_mechanism_analysis_props#
- Analysis.update_component_failure_mechanism_analysis_props(request: UpdateComponentFailureMechanismPropsRequest) list[SherlockCommonService_pb2.ReturnCode] #
Update properties for one or more Component Failure Mechanism analysis.
- Parameters:
request (UpdateComponentFailureMechanismPropsRequest) – Contains all the information needed to update the properties for one or more component failure mechanism analyses per project.
- Returns:
Return codes for each request.
- Return type:
list[SherlockCommonService_pb2.ReturnCode]
Examples
>>> from ansys.sherlock.core.launcher import launch_sherlock >>> from ansys.sherlock.core.types.analysis_types import ( ComponentFailureMechanism, UpdateComponentFailureMechanismPropsRequest, ) >>> sherlock = launch_sherlock() >>> sherlock.project.import_project_zip_archive( project="Assembly Tutorial", category="category", archive_file=\ "C:\\Program Files\\ANSYS Inc\\v252\\sherlock\\tutorial\\Assembly Tutorial.zip", ) >>> update_request1 = ComponentFailureMechanism( cca_name="Main Board", default_part_temp_rise=1.5, default_part_temp_rise_units="K", part_temp_rise_min_enabled=True, part_validation_enabled=False, ) >>> update_request2 = ComponentFailureMechanism( cca_name="Memory Card 1", default_part_temp_rise=-3.25, default_part_temp_rise_units="F", part_temp_rise_min_enabled=False, part_validation_enabled=True, ) >>> request = UpdateComponentFailureMechanismPropsRequest( project="Test", component_failure_mechanism_properties_per_cca=[ update_request1, update_request2 ] ) >>> return_codes = sherlock.analysis.\ update_component_failure_mechanism_analysis_props(request) >>> for return_code in return_codes: print(f"Return code: value={return_code.value}, message={return_code.message}")