public abstract class MagnetPowerSupply extends java.lang.Object implements DataListener
| Modifier and Type | Field and Description |
|---|---|
protected Accelerator |
accelerator |
protected ChannelSuite |
channelSuite |
static java.lang.String |
CURRENT_RB_HANDLE |
static java.lang.String |
CURRENT_SET_HANDLE |
static int |
CYCLE_INVALID |
static java.lang.String |
CYCLE_STATE_HANDLE |
static int |
CYCLE_VALID |
static int |
CYCLING |
protected java.lang.String |
strId |
| Constructor and Description |
|---|
MagnetPowerSupply(Accelerator anAccelerator)
Creates a new instance of PowerSupply
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
dataLabel()
dataLabel() provides the name used to identify the class in an
external data source.
|
Channel |
findChannel(java.lang.String handle)
Find the channel for the specified handle.
|
Channel |
getAndConnectChannel(java.lang.String handle)
Get the channel corresponding to the specified handle and connect it.
|
Channel |
getChannel(java.lang.String handle)
Get the channel for the specified handle.
|
ChannelSuite |
getChannelSuite()
Get the channel suite.
|
double |
getCurrent()
Get the magnet power supply current
|
int |
getCycleState()
Gets the cycle state of the magnet.
|
java.lang.String |
getId()
Get the unique power supply ID
|
java.util.Collection |
getNodes()
Get the accelerator nodes which are tied to this supply.
|
<NodeType extends AcceleratorNode> |
getNodes(java.util.Collection<NodeType> trialNodes)
Get the subset of nodes from trialNodes which are supplied by this power supply.
|
abstract java.lang.String |
getType()
Get the power supply type
|
double |
lowerCurrentLimit()
get the current lower settable limit (A)
|
void |
setCurrent(double current)
Set the magnet power supply current.
|
abstract boolean |
suppliesNode(AcceleratorNode node)
Check if the electromagnet is supplied by this power supply.
|
void |
update(DataAdaptor adaptor)
Instructs the receiver to update its data based on the given adaptor.
|
double |
upperCurrentLimit()
get the current lower settable limit (A)
|
void |
write(DataAdaptor adaptor)
Instructs the receiver to write its data to the adaptor for external
storage.
|
protected Accelerator accelerator
protected ChannelSuite channelSuite
protected java.lang.String strId
public static final int CYCLE_INVALID
public static final int CYCLING
public static final int CYCLE_VALID
public static final java.lang.String CYCLE_STATE_HANDLE
public static final java.lang.String CURRENT_SET_HANDLE
public static final java.lang.String CURRENT_RB_HANDLE
public MagnetPowerSupply(Accelerator anAccelerator)
public java.lang.String getId()
public abstract java.lang.String getType()
public java.lang.String dataLabel()
dataLabel in interface DataListenerpublic void update(DataAdaptor adaptor)
update in interface DataListeneradaptor - The adaptor from which to update the receiver's datapublic void write(DataAdaptor adaptor)
write in interface DataListeneradaptor - The adaptor to which the receiver's data is writtenpublic ChannelSuite getChannelSuite()
public Channel findChannel(java.lang.String handle)
handle - The handle for the channel to fetchpublic Channel getChannel(java.lang.String handle) throws NoSuchChannelException
handle - The handle for the channel to fetchNoSuchChannelExceptionpublic Channel getAndConnectChannel(java.lang.String handle) throws NoSuchChannelException, ConnectionException
handle - The handle for the channel to get.NoSuchChannelException - if no such channel as specified by the handle is associated with this node.ConnectionException - if the channel cannot be connectedpublic int getCycleState()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double getCurrent()
throws ConnectionException,
GetException
ConnectionException - if the readback channel cannot be connectedGetException - if the readback channel get action failspublic void setCurrent(double current)
throws ConnectionException,
PutException
current - The current in amperesConnectionException - if the put channel cannot be connectedPutException - if the put channel set action failspublic double upperCurrentLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic double lowerCurrentLimit()
throws ConnectionException,
GetException
ConnectionExceptionGetExceptionpublic java.util.Collection getNodes()
public <NodeType extends AcceleratorNode> java.util.Collection<NodeType> getNodes(java.util.Collection<NodeType> trialNodes)
trialNodes - The collection of nodes from which to check for matches.public abstract boolean suppliesNode(AcceleratorNode node)
node - The electromagnet to check