Location: Symbol Reference > Functions > CreateLogServer Function
JWSCL Documentation
ContentsIndexHome
PreviousUpNext
CreateLogServer Function
Pascal
function CreateLogServer(Elements: TStringList; const LogTypes: TJwEventTypes; const OnXMLWrite: TJwOnXMLWrite = nil; const OnXMLWriting: TJwOnXMLWriting = nil; const WriterClass: IJwWriterClass = nil): IJwLogServer;
Parameters 
Description 
Elements: TStringList 
receives the xml tags. Each item contains a whole line of an xml tag. Must not be nil if parameter WriterClass is left nil.
 
const LogTypes: TJwEventTypes 
receives a list of TJwEventType records that contains tags and its attributes which ought to be logged. If the array is empty all types of events are logged.
 
const OnXMLWrite: TJwOnXMLWrite = nil 
is a callback method that will be called when an xml line is going to be stored into the log file. The xml line can be adapted or even removed
 
const OnXMLWriting: TJwOnXMLWriting = nil 
is a callback method that will be called when an xml line is going to be created. Some parameters can be changed.
 
const WriterClass: IJwWriterClass = nil 
defines a custom class that can be used to change the default mechanism how xml is stored. By default (if nil) the TJwLogWriterClass uses a string list implementation to store xml.
 

Returns an instance of IJwLogServer for logging information

CreateLogServer creates a new log server that can hold several log clients (IJwLogClient). A log sever creates a new logprocess tag and closes it if it is destroyed. It saves each xml tag into a new string list item in parameter Elements. This behavior can be overwritten by using a non default WriterClass (TJwLogWriterClass)

Copyright (c) 2010. All rights reserved.
This help was created by Doc-O-Matic sponsored by toolsfactory software inc.
What do you think about this topic? Send feedback!