public class CommandListComponent extends AbstractMessageComponent
| Constructor and Description |
|---|
CommandListComponent(java.lang.String name)
Construct a CommandListComponent with no content.
|
CommandListComponent(java.lang.String name,
java.util.Collection<? extends Command> commands)
Construct a CommandListComponent with a specific list of agent commands.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.List<Command> |
getCommands()
Get the agent commands that make up this message component.
|
void |
read(java.io.InputStream in)
Read this component from a stream.
|
void |
setCommands(java.util.Collection<? extends Command> commands)
Set the commands that make up this message component.
|
java.lang.String |
toString() |
void |
write(java.io.OutputStream out)
Write this component to a stream.
|
getNamepublic CommandListComponent(java.lang.String name)
name - The name of the component.public CommandListComponent(java.lang.String name,
java.util.Collection<? extends Command> commands)
name - The name of the component.commands - The agent commands in this message component.public java.util.List<Command> getCommands()
public void setCommands(java.util.Collection<? extends Command> commands)
commands - The commands in this component.public void write(java.io.OutputStream out)
throws java.io.IOException
MessageComponentout - The stream to write to.java.io.IOException - If the write fails.public void read(java.io.InputStream in)
throws java.io.IOException
MessageComponentin - The stream to read from.java.io.IOException - If the read fails.public java.lang.String toString()
toString in class java.lang.Object