Class org.as2lib.env.log.handler.XmlSocketHandler

org.as2lib.core.BasicClass
   +--org.as2lib.env.log.handler.AbstractLogHandler
      +--org.as2lib.env.log.handler.XmlSocketHandler

Implemented Interfaces

LogHandler

Description

XmlSocketHandler uses the XMLSocket to log the message.

It was originally designed to work with the POWERFLASHER's SOS XML-Socket-Server but you can use it for any output device that is accessible over the XML socket.

Method Index

new XmlSocketHandler()

write()

Inherited from BasicClass

toString()

Constructor Detail

XmlSocketHandler

public function XmlSocketHandler(host:String, port:Number, messageStringifier:Stringifier)

Constructs a new XmlSocketHandler instance.

Parameters

hosta fully qualified DNS domain name
portthe TCP port number on the host used to establish a connection
messageStringifier(optional) the log message stringifier to use

Throws

IllegalArgumentExceptionif the passed-in port is null or less than 1024

Method Detail

write

public function write(message:LogMessage):Void

Uses the xml socket connection to log the passed-in message.

The string representation of the message to log is obtained via the convertMessage method.

Parameters

messagethe message to log

Specified By

write() in org.as2lib.env.log.LogHandler