Class ModelUtilInternal


  • public class ModelUtilInternal
    extends java.lang.Object
    Client model utility methods which are not in the public API.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private ModelUtilInternal()
      Static class not intended to be instantiated.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void cancelRunnable()
      Cancels the currently running command, if possible.
      static java.lang.Boolean getConnectedEncryption()
      Returns whether the currently connected server uses a secure connection or not, or null if not connected.
      static java.lang.String getConnectedHost()
      Returns the host of the currently connected server, or null if not connected.
      static java.lang.Integer getConnectedPort()
      Returns the port of the currently connected server, or null if not connected.
      static boolean isApplicationServer()
      Returns true if running in an application server.
      static boolean isGraphicsServer()
      Returns true if running in a graphics server.
      static java.lang.String[] path()
      Returns the search path.
      static void path​(java.lang.String[] path)
      Sets the search path.
      static void setCosimCallbackHandler​(CosimCallbackHandler cosimCallbackHandler)
      Register a handler for cosimulation callbacks, or null to unregister.
      static void setMethodExecImpl​(com.comsol.model.util.impl.IModelUtilImpl modelUtilImpl)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ModelUtilInternal

        private ModelUtilInternal()
        Static class not intended to be instantiated.
    • Method Detail

      • path

        public static java.lang.String[] path()
        Returns the search path. Note: This function is called from the test framework for model .m-tests.
        Returns:
        Directories to search, ordered from first to last.
      • path

        public static void path​(java.lang.String[] path)
        Sets the search path. Note: This function is called from the test framework for model .m-tests.
        Parameters:
        path - Directories to search, ordered from first to last.
      • getConnectedHost

        public static java.lang.String getConnectedHost()
        Returns the host of the currently connected server, or null if not connected.
        Returns:
        The connected server host computer, or null if not connected.
      • getConnectedPort

        public static java.lang.Integer getConnectedPort()
        Returns the port of the currently connected server, or null if not connected.
        Returns:
        The connected port, or null if not connected.
      • getConnectedEncryption

        public static java.lang.Boolean getConnectedEncryption()
        Returns whether the currently connected server uses a secure connection or not, or null if not connected.
        Returns:
        Boolean.TRUE if the current connection is secure, Boolean.FALSE if it's not secure, or null if not connected.
      • isGraphicsServer

        public static boolean isGraphicsServer()
        Returns true if running in a graphics server.
      • isApplicationServer

        public static boolean isApplicationServer()
        Returns true if running in an application server.
      • setCosimCallbackHandler

        public static void setCosimCallbackHandler​(CosimCallbackHandler cosimCallbackHandler)
        Register a handler for cosimulation callbacks, or null to unregister.
        Parameters:
        cosimCallbackHandler - The handler for cosimulation callbacks.
      • cancelRunnable

        public static void cancelRunnable()
        Cancels the currently running command, if possible.
      • setMethodExecImpl

        public static void setMethodExecImpl​(com.comsol.model.util.impl.IModelUtilImpl modelUtilImpl)