Package org.jmol.api

Interface JmolAppletInterface

  • All Superinterfaces:
    JmolSyncInterface
    All Known Implementing Classes:
    GenericApplet, Jmol, Jmol, JmolApplet

    public interface JmolAppletInterface
    extends JmolSyncInterface
    This is the API of methods that are available to JavaScript via LiveConnect to the Jmol applet. DONT FORGET TO ADD THESE FUNCTIONS TO src/JmolApplet.java !!!
    • Method Detail

      • handleEvent

        boolean handleEvent​(Event event)
      • getAppletInfo

        String getAppletInfo()
      • destroy

        void destroy()
      • setStereoGraphics

        Object setStereoGraphics​(boolean isStereo)
      • script

        void script​(String script)
      • scriptWaitOutput

        String scriptWaitOutput​(String script)
      • getModelIndexFromId

        int getModelIndexFromId​(String id)
        Parameters:
        id - some_id, filename#id, or ~fileNo.modelNo added ".basemodel" indicates to get the first model in a series from a JDX-MOL file.
        Returns:
        model index if found; -2 if file found but model not found -2 if no file indicated and no model found -1 if no such file
      • getPropertyAsString

        String getPropertyAsString​(String infoType)
      • getPropertyAsJSON

        String getPropertyAsJSON​(String infoType)
      • loadInlineString

        String loadInlineString​(String strModel,
                                String script,
                                boolean isAppend)
      • loadInlineArray

        String loadInlineArray​(String[] strModels,
                               String script,
                               boolean isAppend)
      • notifyAudioEnded

        void notifyAudioEnded​(Object htParams)
      • loadInline

        @Deprecated
        String loadInline​(String strModel)
        Deprecated.
        Parameters:
        strModel -
        Returns:
        error or null
      • loadInline

        @Deprecated
        String loadInline​(String[] strModels)
        Deprecated.
        Parameters:
        strModels -
        Returns:
        error or null
      • loadInline

        @Deprecated
        String loadInline​(String strModel,
                          String script)
        Deprecated.
        Parameters:
        strModel -
        script -
        Returns:
        error or null
      • loadInline

        @Deprecated
        String loadInline​(String[] strModels,
                          String script)
        Deprecated.
        Parameters:
        strModels -
        script -
        Returns:
        error or null