Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

alma::acs::jlog::test::EngineFilteringTest Class Reference

List of all members.

Public Member Functions

 EngineFilteringTest () throws Exception
Override void acsLogConnConnecting ()
Override void acsLogConnDisconnected ()
Override void acsLogConnEstablished ()
Override void acsLogConnLost ()
Override void acsLogConnSuspended ()
Override void acsLogsDelay ()
Override void reportStatus (String status)
Override void logEntryReceived (ILogEntry logEntry)
Override void xmlEntryReceived (String xmlLogString)
Override void errorReceived (String xml)
void testAddFilter () throws Exception
void testAddFiltersVector () throws Exception
void testFiltering () throws Exception

Protected Member Functions

Override void setUp () throws Exception
Override void tearDown () throws Exception

Private Attributes

LCEngine engine
Vector< ILogEntryreceivedLogs
int xmlLogs = 0
int xmlInfos = 0

Static Private Attributes

final int TIMEOUT = 120
final int NUMBER_OF_LOGS = 100

Detailed Description

A class testing the filtering of logs in the engine.

Author:
acaproni


Constructor & Destructor Documentation

alma::acs::jlog::test::EngineFilteringTest::EngineFilteringTest  )  throws Exception [inline]
 

Constructor

Exceptions:
Exception 


Member Function Documentation

Override void alma::acs::jlog::test::EngineFilteringTest::acsLogConnConnecting  )  [inline]
 

Override void alma::acs::jlog::test::EngineFilteringTest::acsLogConnDisconnected  )  [inline]
 

Disconnected

See also:
com.cosylab.logging.engine.ACS.ACSLogConnectionListener::acsLogConnDisconnected()

Override void alma::acs::jlog::test::EngineFilteringTest::acsLogConnEstablished  )  [inline]
 

See also:
com.cosylab.logging.engine.ACS.ACSLogConnectionListener::acsLogConnEstablished()

Override void alma::acs::jlog::test::EngineFilteringTest::acsLogConnLost  )  [inline]
 

Connection lost: tat will show this situation

See also:
com.cosylab.logging.engine.ACS.ACSLogConnectionListener::acsLogConnLost()

Override void alma::acs::jlog::test::EngineFilteringTest::acsLogConnSuspended  )  [inline]
 

tat will show this situation

See also:
com.cosylab.logging.engine.ACS.ACSLogConnectionListener::acsLogConnSuspended()

Override void alma::acs::jlog::test::EngineFilteringTest::acsLogsDelay  )  [inline]
 

Override void alma::acs::jlog::test::EngineFilteringTest::errorReceived String  xml  )  [inline]
 

Method executed in case of error: print a message in the stdout, tat will show this error

See also:
com.cosylab.logging.engine.ACS.ACSRemoteErrorListener::errorReceived(java.lang.String)

Override void alma::acs::jlog::test::EngineFilteringTest::logEntryReceived ILogEntry  logEntry  )  [inline]
 

Executed whenever a new log is received. Filtering works here.

The received log is added to the vector

See also:
com.cosylab.logging.engine.ACS.ACSRemoteLogListener::logEntryReceived(com.cosylab.logging.engine.log.ILogEntry)

Override void alma::acs::jlog::test::EngineFilteringTest::reportStatus String  status  )  [inline]
 

Override void alma::acs::jlog::test::EngineFilteringTest::setUp  )  throws Exception [inline, protected]
 

Setup the environment by creating the engine with a null set of filters. The engine is disconnected because some of the tests do not need the connection alive.

See also:
alma.acs.component.client.ComponentClientTestCase::setUp()

Override void alma::acs::jlog::test::EngineFilteringTest::tearDown  )  throws Exception [inline, protected]
 

See also:
alma.acs.component.client.ComponentClientTestCase::tearDown()

void alma::acs::jlog::test::EngineFilteringTest::testAddFilter  )  throws Exception [inline]
 

Test the adding and clearing filters

Exceptions:
Exception 

void alma::acs::jlog::test::EngineFilteringTest::testAddFiltersVector  )  throws Exception [inline]
 

Test adding a FiltersVector

void alma::acs::jlog::test::EngineFilteringTest::testFiltering  )  throws Exception [inline]
 

Set a filter and checks if the logs received are those passing a filters.

In this case we do not need to check the correctness of the logs received in the listeners but only if they are received or not because it means that the engine is using the filters.

For this example, the test defines 1 filter based on the type of the logs.

The correctness of the filtering is also tested in another test because the engine uses the same filters used by the table.

Exceptions:
Exception 

Override void alma::acs::jlog::test::EngineFilteringTest::xmlEntryReceived String  xmlLogString  )  [inline]
 

XML entries are not filtered!

See also:
com.cosylab.logging.engine.ACS.ACSRemoteRawLogListener::xmlEntryReceived(java.lang.String)


Member Data Documentation

LCEngine alma::acs::jlog::test::EngineFilteringTest::engine [private]
 

final int alma::acs::jlog::test::EngineFilteringTest::NUMBER_OF_LOGS = 100 [static, private]
 

Vector<ILogEntry> alma::acs::jlog::test::EngineFilteringTest::receivedLogs [private]
 

final int alma::acs::jlog::test::EngineFilteringTest::TIMEOUT = 120 [static, private]
 

int alma::acs::jlog::test::EngineFilteringTest::xmlInfos = 0 [private]
 

int alma::acs::jlog::test::EngineFilteringTest::xmlLogs = 0 [private]
 


The documentation for this class was generated from the following file:
Generated on Thu Apr 30 02:53:35 2009 for ACS Java API by doxygen 1.3.8