public class Relay
extends java.lang.Object
| Constructor and Description |
|---|
Relay(java.lang.String ip,
int p)
Constructs a new Relay object with the specifed target address and port.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addBlob(byte[] b)
Adds a blob argument to all messages contained in this Relay.
|
void |
addBlob(java.lang.String message,
byte[] b)
Adds a blob argument to the specifed OSC message.
|
void |
addFloat(float f)
Adds a float argument to all messages contained in this Relay.
|
void |
addFloat(float f,
float min,
float max)
Adds a float argument mapped to the provided value range.
|
void |
addFloat(java.lang.String message,
float f)
Adds a float argument to the specifed OSC message.
|
void |
addFloat(java.lang.String message,
float f,
float min,
float max)
Adds a float argument to the specifed OSC message that is mapped to the provided value range.
|
void |
addInteger(int i)
Adds an integer argument to all OSC messages contained in this Relay.
|
void |
addInteger(java.lang.String message,
int i)
Adds an integer argument to the specifed OSC message.
|
void |
addLong(long l)
Adds a long argument to all OSC messges contained in this Relay.
|
void |
addLong(java.lang.String message,
long l)
Adds a long argument to the specified OSC message.
|
void |
addMessage(java.lang.String a)
Adds a message to this Relay.
|
void |
addString(java.lang.String s)
Adds a String argument to all messages contained in this Relay.
|
void |
addString(java.lang.String message,
java.lang.String s)
Adds a String argument to the specifed OSC message.
|
void |
clearMessages()
Remove all message associated with this Relay.
|
boolean |
containsMessage(java.lang.String m)
Determines whether the specified message is contained in this Relay.
|
java.lang.String |
getIPAddress()
Returns the IP address associated with this Relay.
|
java.lang.String |
getLabel()
Gets the label for this Relay.
|
int |
getMessageCount()
Returns the number of messages associated with this Relay.
|
java.lang.String[] |
getMessages()
Returns all messages associated with this Relay as an array of Strings.
|
int |
getPort()
Returns the port number associated with this Relay.
|
void |
removeMessage(java.lang.String a)
Removes the specified message.
|
void |
replaceMessage(java.lang.String a1,
java.lang.String a2)
Replaces the specified message with a new message.
|
void |
resetMessage(java.lang.String a)
Resets the specified message without removing it.
|
void |
send()
Sends all messages associated with this Relay
|
void |
send(java.lang.String message)
Sends the specified message.
|
void |
send(java.lang.String[] m)
Sends all messages specifed in the array provided as an argument
|
void |
setLabel(java.lang.String l)
Sets the label for this Relay.
|
void |
setSocket(java.lang.String ip,
int p)
Sets the IP address and port number.
|
public Relay(java.lang.String ip,
int p)
ip - the IP address of the targetp - the port number of the targetpublic void setSocket(java.lang.String ip,
int p)
ip - the IP address of the targetp - the port number of the targetpublic java.lang.String getIPAddress()
public int getPort()
public void setLabel(java.lang.String l)
l - the label Stringpublic java.lang.String getLabel()
public java.lang.String[] getMessages()
public int getMessageCount()
public void addMessage(java.lang.String a)
a - the message string to addpublic void addInteger(int i)
i - the integer to addpublic void addInteger(java.lang.String message,
int i)
message - the message that will receive the integeri - the integer to addpublic void addLong(long l)
l - the long to addpublic void addLong(java.lang.String message,
long l)
message - l - the long to addpublic void addFloat(float f)
f - the float to addpublic void addFloat(java.lang.String message,
float f)
message - the message that will receive the float argumentf - the float to addpublic void addFloat(float f,
float min,
float max)
f - the float to addmin - the minimum value for the rangemax - the maximum value for the rangepublic void addFloat(java.lang.String message,
float f,
float min,
float max)
message - the message that will receive the mapped float argumentf - the float to addmin - the minimum value for the rangemax - the maximum value for the rangepublic void addString(java.lang.String s)
s - the string to addpublic void addString(java.lang.String message,
java.lang.String s)
message - the message that will receive the string arguments - the string to addpublic void addBlob(byte[] b)
b - the blob to addpublic void addBlob(java.lang.String message,
byte[] b)
message - the message that will receive the blob argumentb - the blob to addpublic boolean containsMessage(java.lang.String m)
m - the specified messagepublic void resetMessage(java.lang.String a)
a - the message to resetpublic void replaceMessage(java.lang.String a1,
java.lang.String a2)
a1 - the message to be replaceda2 - the new messagepublic void removeMessage(java.lang.String a)
a - the message to removepublic void clearMessages()
public void send()
public void send(java.lang.String message)
message - the message to sendpublic void send(java.lang.String[] m)
m - an array of messages to send