GetLogOptions Method (.NET)

The GetLogOptions method returns an instance of a LogOptions class which is pre-populated to automatically log all properties which are included in the tested rule set, as well as any related logging options which may be specified in the rules XML.  You could instead create a LogOptions class yourself, but would then have to update your code if you added or removed properties to the rules in the future - otherwise those properties would never be logged.  By using the GetLogOptions you are freed of this responsibility and let BrowserHawk do this work for you.

 

Syntax:

LogOptions logOptions = ruleEngine.GetLogOptions();

 

Returns:

logOptions: An instance of the LogOptions class, ready for use when calling GetLogData or LogData..

 

C# Example:

<%

...

LogOptions logOptions = engine.GetLogOptions();

logOptions.BrwsURL = "http://www.yoursite.com/pathToBRWS/cyScapebrws.dll";

LogDataResults = BrowserObj.GetLogData(browObj, extendedBrowObj, logOptions);

Response.Write(LogDataResults);

%>

 

Tip: See the comments in the rules-basic.aspx sample for more information.

 

Note: This method requires the Enterprise Edition of BrowserHawk

 

See Also:

About BrowserHawk Reports

About the LogOptions class

GetLogData Method (.NET)

About BrowserHawk Reports

About the RuleEngine Class

About Rule Enforcement Technology (RET)