new(
debuglevel
=>0|1|2, - creates the Server object. debugfile
debugfile
=>string, should be set to the path
for
the debug
debugtime
=>0|1)
log
to be written. If set to
"stdout"
then the debug will go there. debuglevel
controls the amount of debug. For more
information about the valid setting
for
debuglevel, debugfile, and debugtime see
Net::Jabber::Debug.
Start(
hostname
=>string, - starts the server listening on the proper
jaberxml
=>string) ports. hostname is a quick way of telling
the server the hostname to
listen
on.
jabberxml defines the path to a different
jabberd configuration file (
default
is
"./jabber.xml"
).
Process(integer) - takes the timeout period as an argument. If
no
timeout is listed then the function blocks
until
a packet is received. Otherwise it waits that
number of seconds and then exits so your program
can
continue
doing useful things. NOTE: This is
important
for
GUIs. You need to leave
time
to
process GUI commands even
if
you are waiting
for
packets. The following are the possible
return
values
for
each
hash entry, and what they mean:
1 - Status ok, data received.
0 - Status ok,
no
data received.
undef
- Status not ok, stop processing.
IMPORTANT: You need to check the output of every
Process. If you get an
undef
then the connection
died and you should behave accordingly.
Stop() - stops the server from running and shuts down all
sub
programs.