|
FUNCTION variable_value_type (variable : GENERIC) : STRING; LOCAL svt : STRING ; feacr : STRING ; variable_typeof : SET [ 1 : ? ] OF STRING ; END_LOCAL ; svt := 'fea_scalar_vector_tensor_schema.' ; feacr := 'finite_element_analysis_control_and_result_schema.' ; variable_typeof := TYPEOF ( variable ) ; IF SIZEOF ( [ ( feacr + 'curve_scalar_variable' ) , ( feacr + 'surface_scalar_variable' ) , ( feacr + 'volume_scalar_variable' ) , ( feacr + 'boundary_curve_scalar_variable' ) , ( feacr + 'boundary_surface_scalar_variable' ) , ( feacr + 'aggregated_scalar_variable' ) , ( feacr + 'volume_angular_variable' ) , ( feacr + 'aggregated_angular_variable' ) , ( feacr + 'application_defined_scalar_variable' ) ] * variable_typeof ) = 1 THEN RETURN ( svt + 'scalar' ) ; END_IF ; IF SIZEOF ( [ ( feacr + 'curve_vector_2d_variable' ) , ( feacr + 'surface_vector_2d_variable' ) , ( feacr + 'application_defined_vector_2d_variable' ) ] * variable_typeof ) = 1 THEN RETURN ( svt + 'tensor1_2d' ) ; END_IF ; IF SIZEOF ( [ ( feacr + 'curve_vector_3d_variable' ) , ( feacr + 'surface_vector_3d_variable' ) , ( feacr + 'volume_vector_3d_variable' ) , ( feacr + 'boundary_curve_vector_3d_variable' ) , ( feacr + 'boundary_surface_vector_3d_variable' ) , ( feacr + 'aggregated_vector_3d_variable' ) , ( feacr + 'application_defined_vector_3d_variable' ) ] * variable_typeof ) = 1 THEN RETURN ( svt + 'tensor1_3d' ) ; END_IF ; IF SIZEOF ( [ ( feacr + 'surface_tensor2_2d_variable' ) , ( feacr + 'application_defined_tensor2_2d_variable' ) ] * variable_typeof ) = 1 THEN RETURN ( svt + 'symmetric_tensor2_3d' ) ; END_IF ; IF SIZEOF ( [ ( feacr + 'volume_tensor2_3d_variable' ) , ( feacr + 'aggregated_tensor2_3d_variable' ) , ( feacr + 'application_defined_tensor2_3d_variable' ) ] * variable_typeof ) = 1 THEN RETURN ( svt + 'symmetric_tensor2_3d' ) ; END_IF ; RETURN ( 'no_match' ) ; END_FUNCTION; -- variable_value_type |
|
public class FVariable_value_type public static Value run(SdaiContext _context, Value variable) |