ECS_EventFilter

- A filter for ECS events

SYNOPSIS

#include <ECS/EventFilter.hh>
class ECS_EventFilter
{
 public:
	_ECSAIO_PRIVAPI ECS_EventFilter();
	_ECSAIO_PRIVAPI ECS_EventFilter(const char* encodingType);
	_ECSAIO_PRIVAPI ECS_EventFilter
	(
	  const char* encodingType,
	  const char* eventSyntax
	);
	_ECSAIO_PRIVAPI ECS_EventFilter(ECS_EventFilter const& other);
	ECS_EventFilter const& operator=(ECS_EventFilter const& other);
	_ECSAIO_PRIVAPI virtual ~ECS_EventFilter();
	virtual ostream& print(ostream& os) const;
	_ECSAIO_PRIVAPI const char* getEncodingTypePattern() const;
	_ECSAIO_PRIVAPI const char* getSyntaxPattern() const;
	_ECSAIO_PRIVAPI void setEncodingTypePattern(const char* pattern);
	_ECSAIO_PRIVAPI void clearEncodingTypePattern();
	_ECSAIO_PRIVAPI void setSyntaxPattern(const char* pattern);
	_ECSAIO_PRIVAPI void clearSyntaxPattern();
	_ECSAIO_PRIVAPI void clear();
};

CLASS TYPE

Concrete

AUDIENCE

ECS Application Developers

DESCRIPTION

This class is used to specify the filtering which is to be applied to events output by the engine before they are passed to an ECS_EventReceiver. Note: Although this class refers to filter components as patterns, the underlying implementation currently only supports an exact match. This means that filtering is limited to a specific encoding type and/or specific event syntax.

Constructors and Destructors

_ECSAIO_PRIVAPI ECS_EventFilter();
The default constructor

The default filter will match all events.

_ECSAIO_PRIVAPI ECS_EventFilter(const char* encodingType);
Constructor
_ECSAIO_PRIVAPI ECS_EventFilter(
const char* encodingType,
const char* eventSyntax
);
Constructor
_ECSAIO_PRIVAPI ECS_EventFilter(ECS_EventFilter const& other);
The copy constructor
ECS_EventFilter const& operator=(ECS_EventFilter const& other);
The assignment operator
_ECSAIO_PRIVAPI virtual ~ECS_EventFilter();
The destructor

Utility

virtual ostream& print(ostream& os) const;
Prints a textual representation of the class to the output stream specified via os.

Access

_ECSAIO_PRIVAPI const char* getEncodingTypePattern() const;
Returns a string containing the current pattern, which is matched against the encoding type of an event being compared with this filter.
_ECSAIO_PRIVAPI const char* getSyntaxPattern() const;
Returns a string containing the current pattern, which is matched against the syntax of an event being compared with this filter.

Modification

_ECSAIO_PRIVAPI void setEncodingTypePattern(const char* pattern);
Sets the current pattern which is matched against the encoding type of an event being compared with this filter.
_ECSAIO_PRIVAPI void clearEncodingTypePattern();
Resets the pattern which is matched against the encoding type of an event being compared with this filter so that all encoding types will be matched.
_ECSAIO_PRIVAPI void setSyntaxPattern(const char* pattern);
Sets the current pattern which is matched against the syntax of an event being compared with this filter.
_ECSAIO_PRIVAPI void clearSyntaxPattern();
Resets the pattern which is matched against the syntax of an event being compared with this filter so that any syntax will match this filter.
_ECSAIO_PRIVAPI void clear();
Clears the filter so that it will match any event.

NOTES

None

SEE ALSO

ECS_EventReceiver

LIBRARY

ECS

VERSION

1.5

DATE RELEASED

1998/02/25

AUTHOR(S)

Hewlett-Packard Company

COPYRIGHT

Copyright (c) 1997 Hewlett-Packard Company. All Rights Reserved.