|
FUNCTION domain_from (ref : maths_space_or_function) : tuple_space; LOCAL typenames : SET OF STRING := stripped_typeof ( ref ) ; func : maths_function ; END_LOCAL ; IF NOT EXISTS ( ref ) THEN RETURN ( ? ) ; END_IF ; IF 'tuple_space' IN typenames THEN RETURN ( ref ) ; END_IF ; IF 'maths_space' IN typenames THEN RETURN ( one_tuples_of ( ref ) ) ; END_IF ; func := ref ; IF 'constant_function' IN typenames THEN RETURN ( domain_from ( func \ constant_function . source_of_domain ) ) ; END_IF ; IF 'selector_function' IN typenames THEN RETURN ( domain_from ( func \ selector_function . source_of_domain ) ) ; END_IF ; IF 'parallel_composed_function' IN typenames THEN RETURN ( domain_from ( func \ parallel_composed_function . source_of_domain ) ) ; END_IF ; RETURN ( func . domain ) ; END_FUNCTION; -- domain_from |
|
public class FDomain_from public static Value run(SdaiContext _context, Value ref) |