Changes between Version 24 and Version 25 of Configuration
- Timestamp:
- 02/20/14 14:25:33 (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Configuration
v24 v25 31 31 === Non-Java instances === 32 32 33 For non-Java instances that use the MUSCLE API, the Ruby classes `NativeInstance` (any executable binary), `PythonInstance` (Python script), `MPIInstance` (executable binary using MPI), and `MatlabInstance` (Matlab script) may be used. The first argument is the instance name, the second is the executable or script. After that, a number of optional arguments may be provided: 33 For non-Java instances that use the MUSCLE API, the Ruby classes `NativeInstance` (any executable binary), `PythonInstance` (Python script), `MPIInstance` (executable binary using MPI), and `MatlabInstance` (Matlab script) may be used. The first parameter of the constructor is the instance name, the second is the executable or script. 34 For a normal executable, for example: 35 {{{ 36 w = NativeInstance.new('w', '/path/to/w') 37 }}} 38 39 Optional parameters may also be provided: 34 40 ||= Parameter =||= Meaning =||= Example =||= Recognized by class =|| 35 41 || `args` || Arguments to the script or executable || `'param1 param2'` || All || … … 40 46 || `matlab_args` || Arguments to Matlab || `'-matlab_arg1 -matlab_arg2'` || `MatlabInstance` || 41 47 || `python` || Command to run Python || `'/opt/bin/python'` || `PythonInstance` || 48 The optional arguments are specified by stating the parameter, a colon, and the parameter value. 42 49 43 The optional arguments are specified by stating the parameter, a colon, and the parameter value. For a normal executable, for example: 44 {{{ 45 w = NativeInstance.new('w', '/path/to/w') 46 }}} 47 to provide arguments and a Java class, state 50 To provide arguments and a Java class to an executable, state for example: 48 51 {{{ 49 52 w = NativeInstance.new('w', '/path/to/w', args: 'param1 param2', java_class: 'uni.dep.MyNativeKernel')