|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Responder
A Responder
is an object that processes
and logs input via a given channel (text, html, flash, etc.).
Method Summary | |
---|---|
java.lang.String |
append(java.lang.String input,
java.lang.String reply,
java.lang.String appendTo)
Response by a Responder is considered an
"append" to some previous string. |
void |
log(java.lang.String input,
java.lang.String reply,
java.lang.String hostname,
java.lang.String userid,
java.lang.String botid)
Logs an input/response pair to the appropriate place. |
java.lang.String |
postprocess(java.lang.String reply)
Postprocesses a message from a bot as appropriate for a given channel. |
java.lang.String |
preprocess(java.lang.String message,
java.lang.String hostname)
Preprocesses a message from a bot as appropriate for a given channel. |
Method Detail |
---|
java.lang.String preprocess(java.lang.String message, java.lang.String hostname)
Preprocesses a message from a bot as appropriate for a given channel.
For some channels, this may involve doing substitutions on the message; for some channels this may mean formatting the message in a particular way, etc.
message
- the message to be formattedhostname
- the name of the host that is generating the message
void log(java.lang.String input, java.lang.String reply, java.lang.String hostname, java.lang.String userid, java.lang.String botid)
input
- the client's inputreply
- the bot's responsehostname
- the name of the hostjava.lang.String append(java.lang.String input, java.lang.String reply, java.lang.String appendTo)
Response by a Responder
is considered an
"append" to some previous string. That string
might be some form of the previous exchange, or it might
be nothing.
input
- an input from the clientreply
- a reply from the botappendTo
- the string to which the client of the
Responder
may expect the reply to be appended
Responder
has decided to modify itjava.lang.String postprocess(java.lang.String reply)
Postprocesses a message from a bot as appropriate for a given channel.
For some channels, this may involve doing substitutions on the message; for some channels this may mean formatting the message in a particular way, etc.
message
- the message to be formattedhostname
- the name of the host that is generating the message
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |