|
" 2013 FRC Java API " |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.wpi.first.wpilibj.networktables2.NetworkTableNode
public abstract class NetworkTableNode
represents a node (either a client or a server) in a network tables 2.0
implementers of the class must ensure that they call #init(NetworkTableTransactionPool, AbstractNetworkTableEntryStore)
before calling any other methods on this class
Field Summary | |
---|---|
protected AbstractNetworkTableEntryStore |
entryStore
|
Constructor Summary | |
---|---|
NetworkTableNode()
|
Method Summary | |
---|---|
void |
addConnectionListener(IRemoteConnectionListener listener,
boolean immediateNotify)
Register an object to listen for connection and disconnection events |
void |
addTableListener(ITableListener listener,
boolean immediateNotify)
|
abstract void |
close()
close all networking activity related to this node |
boolean |
containsKey(String key)
|
void |
fireConnectedEvent()
called when something is connected |
void |
fireDisconnectedEvent()
called when something is disconnected |
void |
fireTableListeners(String key,
Object value,
boolean isNew)
Called when the object should fire it's listeners |
boolean |
getBoolean(String name)
|
double |
getDouble(String name)
|
AbstractNetworkTableEntryStore |
getEntryStore()
|
String |
getString(String name)
|
Object |
getValue(String name)
|
protected void |
init(AbstractNetworkTableEntryStore entryStore)
|
void |
putBoolean(String name,
boolean value)
|
void |
putComplex(String name,
ComplexData value)
|
void |
putDouble(String name,
double value)
|
void |
putString(String name,
String value)
|
void |
putValue(NetworkTableEntry entry,
Object value)
|
void |
putValue(String name,
NetworkTableEntryType type,
Object value)
Put a value with a specific network table type |
void |
putValue(String name,
Object value)
|
void |
removeConnectionListener(IRemoteConnectionListener listener)
Unregister a listener from connection events |
void |
removeTableListener(ITableListener listener)
|
void |
retrieveValue(String name,
Object externalData)
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface edu.wpi.first.wpilibj.tables.IRemote |
---|
isConnected, isServer |
Field Detail |
---|
protected AbstractNetworkTableEntryStore entryStore
Constructor Detail |
---|
public NetworkTableNode()
Method Detail |
---|
protected final void init(AbstractNetworkTableEntryStore entryStore)
public AbstractNetworkTableEntryStore getEntryStore()
public void putBoolean(String name, boolean value)
public boolean getBoolean(String name) throws TableKeyNotDefinedException
TableKeyNotDefinedException
public void putDouble(String name, double value)
public double getDouble(String name) throws TableKeyNotDefinedException
TableKeyNotDefinedException
public void putString(String name, String value)
public String getString(String name) throws TableKeyNotDefinedException
TableKeyNotDefinedException
public void putComplex(String name, ComplexData value)
public void retrieveValue(String name, Object externalData) throws TableKeyNotDefinedException
TableKeyNotDefinedException
public void putValue(String name, Object value) throws IllegalArgumentException
IllegalArgumentException
public void putValue(String name, NetworkTableEntryType type, Object value)
name
- the name of the entry to associate with the given valuetype
- the type of the entryvalue
- the actual value of the entrypublic void putValue(NetworkTableEntry entry, Object value)
public Object getValue(String name) throws TableKeyNotDefinedException
TableKeyNotDefinedException
public boolean containsKey(String key)
key
- the key to check for existence
public abstract void close()
public void addConnectionListener(IRemoteConnectionListener listener, boolean immediateNotify)
IRemote
addConnectionListener
in interface IRemote
listener
- the listener to be registerimmediateNotify
- if the listener object should be notified of the current connection statepublic void removeConnectionListener(IRemoteConnectionListener listener)
IRemote
removeConnectionListener
in interface IRemote
listener
- the listener to be unregisteredpublic void fireConnectedEvent()
ClientConnectionListenerManager
fireConnectedEvent
in interface ClientConnectionListenerManager
public void fireDisconnectedEvent()
ClientConnectionListenerManager
fireDisconnectedEvent
in interface ClientConnectionListenerManager
public void addTableListener(ITableListener listener, boolean immediateNotify)
public void removeTableListener(ITableListener listener)
public void fireTableListeners(String key, Object value, boolean isNew)
AbstractNetworkTableEntryStore.TableListenerManager
fireTableListeners
in interface AbstractNetworkTableEntryStore.TableListenerManager
|
" 2013 FRC Java API " |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |