Scheme interpreter#
High-level scheme interpreter wrappers.
This module owns the business-logic layer on top of the SchemeInterpreter gRPC service. The grpc service implementation lives in:
ansys.fluent.core._grpc_services.scheme_interpreter_service(v1 proto API)ansys.fluent.core._grpc_services.scheme_interpreter_service_v0(v0 proto API)
Class hierarchy#
SchemeInterpretergRPC-based implementation (v1 and v0 proto API).
Example#
>>> session.scheme.exec(('(ti-menu-load-string "/report/system/proc-stats")',))
>>> # Returns TUI output string
>>> session.scheme.eval("(+ 2 3)")
5
>>> session.scheme.eval("(rpgetvar 'mom/relax)")
0.7
Classes:
|
SchemeInterpreter backed by the SchemeInterpreter gRPC service. |
- class ansys.fluent.core.services.scheme_interpreter.SchemeInterpreter(service)#
Bases:
AbstractSchemeInterpreterSchemeInterpreter backed by the SchemeInterpreter gRPC service.
Methods:
__init__(service)Initialize SchemeInterpreter.
eval(scm_input[, suppress_prompts])Evaluates a scheme expression in string format.
exec(commands[, wait, silent])Executes a sequence of scheme commands.
is_defined(symbol)Check if a symbol is defined in the scheme environment.
scheme_eval(scm_input[, suppress_prompts])Evaluates a scheme expression in string format.
string_eval(input)Evaluates a scheme expression in string format.
- __init__(service)#
Initialize SchemeInterpreter.
- eval(scm_input, suppress_prompts=True)#
Evaluates a scheme expression in string format.
- exec(commands, wait=True, silent=True)#
Executes a sequence of scheme commands.
- is_defined(symbol)#
Check if a symbol is defined in the scheme environment.
- scheme_eval(scm_input, suppress_prompts=True)#
Evaluates a scheme expression in string format.
Deprecated since version 0.32: Use
session.scheme.