Package org.yamcs.management
Class LinkManager
- java.lang.Object
-
- org.yamcs.management.LinkManager
-
public class LinkManager extends Object
Service that manages all the data links:- is endpoint for the /links API calls
- for the commanding links it will only send commands if the link is enabled. If no commanding link is enabled, a negative Sent ACK will be produced.
- TODO: can set exclusive flags - i.e. only one link from a group can be enabled at a time
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classLinkManager.LinkWithInfo
-
Constructor Summary
Constructors Constructor Description LinkManager(String instanceName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanaddLinkListener(LinkListener l)Adds a listener that is to be notified when any processor, or any client is updated.voiddisableLink(String linkName)voidenableLink(String linkName)LinkgetLink(String linkName)Return the link by the given name or null if there is no such link.List<org.yamcs.protobuf.LinkInfo>getLinkInfo()org.yamcs.protobuf.LinkInfogetLinkInfo(String linkName)Optional<LinkManager.LinkWithInfo>getLinkWithInfo(String linkName)booleanremoveLinkListener(LinkListener l)voidresetCounters(String linkName)voidstartLinks()voidstopLinks()
-
-
-
Constructor Detail
-
LinkManager
public LinkManager(String instanceName) throws InitException
- Throws:
InitException
-
-
Method Detail
-
startLinks
public void startLinks()
-
stopLinks
public void stopLinks()
-
getLinkWithInfo
public Optional<LinkManager.LinkWithInfo> getLinkWithInfo(String linkName)
-
addLinkListener
public boolean addLinkListener(LinkListener l)
Adds a listener that is to be notified when any processor, or any client is updated. Calling this multiple times has no extra effects. Either you listen, or you don't.
-
enableLink
public void enableLink(String linkName)
-
disableLink
public void disableLink(String linkName)
-
resetCounters
public void resetCounters(String linkName)
-
removeLinkListener
public boolean removeLinkListener(LinkListener l)
-
getLinkInfo
public List<org.yamcs.protobuf.LinkInfo> getLinkInfo()
-
getLinkInfo
public org.yamcs.protobuf.LinkInfo getLinkInfo(String linkName)
-
-