matlabcontrol.extensions
Class MatlabProxyLogger

java.lang.Object
  extended by matlabcontrol.extensions.MatlabProxyLogger

Deprecated. Replaced by LoggingMatlabProxy. Wraps around a MatlabProxy to provide a log of interactions. The data is not altered. This logger is useful for determining the Java types and structure of data returned from MATLAB.

Entering a method, exiting a method, and throwing an exception are logged. Method parameters and return values are logged. The contents of a returned array will be recursively explored and its contents logged. As is convention, all of these interactions are logged at Level.FINER. If the logging system has not been otherwise configured, then the ConsoleHandler which prints log messages to the console will not show these log messages as their level is too low. To configure the ConsoleHandler to show these log messages, call showInConsoleHandler().

This class is unconditionally thread-safe.

public class MatlabProxyLogger
extends java.lang.Object

Since:
4.0.0

Constructor Summary
MatlabProxyLogger(MatlabProxy proxy)
          Deprecated. Constructs the logger.
 
Method Summary
 void addDisconnectionListener(MatlabProxy.DisconnectionListener listener)
          Deprecated. Delegates to the proxy; logs the interaction.
 boolean disconnect()
          Deprecated. Delegates to the proxy; logs the interaction.
 void eval(java.lang.String command)
          Deprecated. Delegates to the proxy; logs the interaction.
 void exit()
          Deprecated. Delegates to the proxy; logs the interaction.
 void feval(java.lang.String functionName, java.lang.Object... args)
          Deprecated. Delegates to the proxy; logs the interaction.
 MatlabProxy.Identifier getIdentifier()
          Deprecated. Delegates to the proxy; logs the interaction.
 java.lang.Object getVariable(java.lang.String variableName)
          Deprecated. Delegates to the proxy; logs the interaction.
<U> U
invokeAndWait(MatlabProxy.MatlabThreadCallable<U> callable)
          Deprecated. Delegates to the proxy; logs the interaction.
 boolean isConnected()
          Deprecated. Delegates to the proxy; logs the interaction.
 boolean isExistingSession()
          Deprecated. Delegates to the proxy; logs the interaction.
 boolean isRunningInsideMatlab()
          Deprecated. Delegates to the proxy; logs the interaction.
 void removeDisconnectionListener(MatlabProxy.DisconnectionListener listener)
          Deprecated. Delegates to the proxy; logs the interaction.
 java.lang.Object[] returningEval(java.lang.String command, int nargout)
          Deprecated. Delegates to the proxy; logs the interaction.
 java.lang.Object[] returningFeval(java.lang.String functionName, int nargout, java.lang.Object... args)
          Deprecated. Delegates to the proxy; logs the interaction.
 void setVariable(java.lang.String variableName, java.lang.Object value)
          Deprecated. Delegates to the proxy; logs the interaction.
static void showInConsoleHandler()
          Deprecated. Configures the ConsoleHandler responsible for showing logging records to show the records that are logged by this interactor.
 java.lang.String toString()
          Deprecated. Returns a brief description of this proxy.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MatlabProxyLogger

public MatlabProxyLogger(MatlabProxy proxy)
Deprecated. 
Constructs the logger. If the provided proxy throws an exception it will be caught, logged, and then rethrown.

Parameters:
proxy -
Method Detail

showInConsoleHandler

public static void showInConsoleHandler()
Deprecated. 
Configures the ConsoleHandler responsible for showing logging records to show the records that are logged by this interactor. This is behavior is useful if you have not otherwise configured logging in your application.


eval

public void eval(java.lang.String command)
          throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
command -
Throws:
MatlabInvocationException

returningEval

public java.lang.Object[] returningEval(java.lang.String command,
                                        int nargout)
                                 throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
command -
nargout -
Returns:
Throws:
MatlabInvocationExceptio
MatlabInvocationException

feval

public void feval(java.lang.String functionName,
                  java.lang.Object... args)
           throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
functionName -
args -
Throws:
MatlabInvocationException

returningFeval

public java.lang.Object[] returningFeval(java.lang.String functionName,
                                         int nargout,
                                         java.lang.Object... args)
                                  throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
functionName -
nargout -
args -
Returns:
Throws:
MatlabInvocationException

setVariable

public void setVariable(java.lang.String variableName,
                        java.lang.Object value)
                 throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
variableName -
value -
Throws:
MatlabInvocationException

getVariable

public java.lang.Object getVariable(java.lang.String variableName)
                             throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
variableName -
Returns:
Throws:
MatlabInvocationException

invokeAndWait

public <U> U invokeAndWait(MatlabProxy.MatlabThreadCallable<U> callable)
                throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Type Parameters:
U -
Parameters:
callable -
Returns:
Throws:
MatlabInvocationException

addDisconnectionListener

public void addDisconnectionListener(MatlabProxy.DisconnectionListener listener)
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
listener -

removeDisconnectionListener

public void removeDisconnectionListener(MatlabProxy.DisconnectionListener listener)
Deprecated. 
Delegates to the proxy; logs the interaction.

Parameters:
listener -

disconnect

public boolean disconnect()
Deprecated. 
Delegates to the proxy; logs the interaction.

Returns:

isExistingSession

public boolean isExistingSession()
Deprecated. 
Delegates to the proxy; logs the interaction.

Returns:

isRunningInsideMatlab

public boolean isRunningInsideMatlab()
Deprecated. 
Delegates to the proxy; logs the interaction.

Returns:

isConnected

public boolean isConnected()
Deprecated. 
Delegates to the proxy; logs the interaction.

Returns:

getIdentifier

public MatlabProxy.Identifier getIdentifier()
Deprecated. 
Delegates to the proxy; logs the interaction.

Returns:

exit

public void exit()
          throws MatlabInvocationException
Deprecated. 
Delegates to the proxy; logs the interaction.

Throws:
MatlabInvocationException

toString

public java.lang.String toString()
Deprecated. 
Returns a brief description of this proxy. The exact details of this representation are unspecified and are subject to change.

Overrides:
toString in class java.lang.Object
Returns: