|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlcm.lcm.LCM
public class LCM
Lightweight Communications and Marshalling Java implementation
Constructor Summary | |
---|---|
LCM(java.lang.String... urls)
Create a new LCM object, connecting to one or more URLs. |
Method Summary | |
---|---|
void |
close()
Call this function to release all resources used by the LCM instance. |
int |
getNumSubscriptions()
Return the number of subscriptions. |
static LCM |
getSingleton()
Retrieve a default instance of LCM using either the environment variable LCM_DEFAULT_URL or the default. |
static void |
main(java.lang.String[] args)
Minimalist test code. |
void |
publish(java.lang.String channel,
byte[] data,
int offset,
int length)
Publish raw data on a channel, bypassing the LCM type specification. |
void |
publish(java.lang.String channel,
LCMEncodable e)
Publish an LCM-defined type on a channel. |
void |
publish(java.lang.String channel,
java.lang.String s)
Publish a string on a channel. |
void |
receiveMessage(java.lang.String channel,
byte[] data,
int offset,
int length)
Not for use by end users. |
void |
subscribe(java.lang.String regex,
LCMSubscriber sub)
Subscribe to all channels whose name matches the regular expression. |
void |
subscribeAll(LCMSubscriber sub)
A convenience function that subscribes to all LCM channels. |
void |
unsubscribe(java.lang.String regex,
LCMSubscriber sub)
Remove this particular regex/subscriber pair (UNTESTED AND API MAY CHANGE). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LCM(java.lang.String... urls) throws java.io.IOException
java.io.IOException
Method Detail |
---|
public static LCM getSingleton()
public int getNumSubscriptions()
public void publish(java.lang.String channel, java.lang.String s) throws java.io.IOException
java.io.IOException
public void publish(java.lang.String channel, LCMEncodable e)
public void publish(java.lang.String channel, byte[] data, int offset, int length) throws java.io.IOException
java.io.IOException
public void subscribe(java.lang.String regex, LCMSubscriber sub)
public void unsubscribe(java.lang.String regex, LCMSubscriber sub)
public void receiveMessage(java.lang.String channel, byte[] data, int offset, int length)
public void subscribeAll(LCMSubscriber sub)
public void close()
public static void main(java.lang.String[] args)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |