Configuration

class Configuration

Contains important configuration information regarding the setup of MATLAB and matlabcontrol.

Author:Joshua Kaplan

Methods

getClassPathAsCanonicalPaths

static String[] getClassPathAsCanonicalPaths()

Converts the classpath into individual canonical entries.

Throws:

getClassPathAsRMICodebase

static String getClassPathAsRMICodebase()

Converts the classpath into RMI’s codebase format. The codebase format is a list of URL formatted strings separated by spaces. As the application may be running in a different directory, paths are made absolute.

Throws:
Returns:

codebase

getMatlabLocation

static String getMatlabLocation()

Returns the location or alias of MATLAB on an operating system specific basis. For OS X this will be the location, for Windows or Linux this will be an alias. For any other operating system an exception will be thrown.

Throws:
  • MatlabConnectionException – thrown if the location of MATLAB cannot be determined on OS X, or the alias cannot be determined because the operating system is not Windows or Linux

getSupportCodeLocation

static String getSupportCodeLocation()

Determines the location of this source code. Either it will be the directory or jar this .class file is in. (That is, the .class file built from compiling this .java file.) Returned as a string so that it may be used by MATLAB.

Throws:

isLinux

static boolean isLinux()

If running on Linux.

isOSX

static boolean isOSX()

If running on OS X.

isRunningInsideMatlab

static boolean isRunningInsideMatlab()

Whether this code is running inside of MATLAB.

isWindows

static boolean isWindows()

If running on Windows.