Class JCACommandThread

java.lang.Object
java.lang.Thread
org.epics.archiverappliance.engine.pv.JCACommandThread
All Implemented Interfaces:
Runnable

public class JCACommandThread extends Thread
Version:
Initial version:CSS, 4-Jun-2012, Luofeng Li:added codes to support for the new archiver
Author:
Kay Kasemir
  • Constructor Details

  • Method Details

    • start

      public void start()
      Version of start that may be called multiple times.

      The thread must only be started after the first PV has been created. Otherwise, if flush is called without PVs, JNI JCA reports pthread errors.

      NOP when already running

      Overrides:
      start in class Thread
    • shutdown

      public void shutdown() throws InterruptedException
      Stop the thread and wait for it to finish
      Throws:
      InterruptedException -  
    • createChannel

      public gov.aps.jca.Channel createChannel(String name, gov.aps.jca.event.ConnectionListener conn_callback) throws IllegalStateException, gov.aps.jca.CAException
      Throws:
      IllegalStateException
      gov.aps.jca.CAException
    • hasContextBeenInitialized

      public boolean hasContextBeenInitialized()
    • doesChannelContextMatchThreadContext

      public boolean doesChannelContextMatchThreadContext(gov.aps.jca.Channel channel)
    • getAllChannelsForPV

      public List<gov.aps.jca.Channel> getAllChannelsForPV(String pvNameOnly)
    • getTotalChannelCount

      public int getTotalChannelCount()
    • getChannelsWithPendingSearchRequests

      public int getChannelsWithPendingSearchRequests()
    • addCommand

      public void addCommand(Runnable command)
      Add a command to the queue. add some cap on the command queue? At least for value updates?
      Parameters:
      command - Runnable
    • run

      public void run()
      Specified by:
      run in interface Runnable
      Overrides:
      run in class Thread
    • getCommandThreadDetails

      public List<Map<String,String>> getCommandThreadDetails()