SpinThread
Date: 2019-10-22

org.jmol.thread

## Class SpinThread

- java.lang.Object
- - java.lang.Thread
  - - org.jmol.thread.JmolThread
    - - org.jmol.thread.SpinThread

- All Implemented Interfaces:
    java.lang.Runnable

      public class SpinThread
      extends JmolThread

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class java.lang.Thread

      `java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `private float` | `angle`
    `private javajs.util.BS` | `bsAtoms`
    `private javajs.util.BS[]` | `bsBranches`
    `private float[]` | `dihedralList`
    `private float` | `endDegrees`
    `private javajs.util.Lst<javajs.util.P3>` | `endPositions`
    `private boolean` | `haveNotified`
    `private int` | `index`
    `private boolean` | `isDone`
    `private boolean` | `isGesture`
    `private boolean` | `isNav`
    `private javajs.util.M4` | `m4`
    `private float` | `myFps`
    `private float` | `nDegrees`
    `private TransformManager` | `transformManager`

    - ### Fields inherited from class org.jmol.thread.JmolThread

      `CHECK1, CHECK2, CHECK3, currentTime, eval, FINISH, haveReference, hoverEnabled, INIT, isJS, isReset, junk, lastRepaintTime, MAIN, name, sc, sleepTime, startTime, stopped, targetTime, useTimeout, vwr`

    - ### Fields inherited from class java.lang.Thread

      `MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SpinThread()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `private void` | `doTransform()`
    `protected void` | `run1(int mode)` Java: run1(INIT) while(!interrupted()) { run1(MAIN) } run1(FINISH) JavaScript: run1(INIT) run1(MAIN) --> setTimeout to run1(CHECK) or run1(FINISH) and return run1(CHECK) --> setTimeout to run1(CHECK) or run1(MAIN) or run1(FINISH) and return
    `int` | `setManager(java.lang.Object manager, Viewer vwr, java.lang.Object params)`

    - ### Methods inherited from class org.jmol.thread.JmolThread

      `checkInterrupted, interrupt, oops, reset, resumeEval, run, runSleep, setEval, setViewer, start`

    - ### Methods inherited from class java.lang.Thread

      `activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, stop, stop, suspend, toString, yield`

    - ### Methods inherited from class java.lang.Object

      `equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### transformManager

          private TransformManager transformManager

    - #### endDegrees

          private float endDegrees

    - #### endPositions

          private javajs.util.Lst<javajs.util.P3> endPositions

    - #### dihedralList

          private float[] dihedralList

    - #### nDegrees

          private float nDegrees

    - #### bsAtoms

          private javajs.util.BS bsAtoms

    - #### isNav

          private boolean isNav

    - #### isGesture

          private boolean isGesture

    - #### myFps

          private float myFps

    - #### angle

          private float angle

    - #### haveNotified

          private boolean haveNotified

    - #### index

          private int index

    - #### bsBranches

          private javajs.util.BS[] bsBranches

    - #### isDone

          private boolean isDone

    - #### m4

          private javajs.util.M4 m4

  - ### Constructor Detail

    - #### SpinThread

          public SpinThread()

  - ### Method Detail

    - #### setManager

          public int setManager(java.lang.Object manager,
                                Viewer vwr,
                                java.lang.Object params)

      Overrides:
        `setManager` in class `JmolThread`
      Returns:
        TODO

    - #### run1

          protected void run1(int mode)
                       throws java.lang.InterruptedException

      Java: run1(INIT) while(!interrupted()) { run1(MAIN) } run1(FINISH) JavaScript: run1(INIT) run1(MAIN) --> setTimeout to run1(CHECK) or run1(FINISH) and return run1(CHECK) --> setTimeout to run1(CHECK) or run1(MAIN) or run1(FINISH) and return
      Specified by:
        `run1` in class `JmolThread`
      Throws:
        `java.lang.InterruptedException`

    - #### doTransform

          private void doTransform()