Apama API Reference for .NET  9.10.0.4
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
Apama.Event.Parser.EventParser Class Reference

Provides the functionality to parse System.String objects into Apama Apama.Event.Event objects, for any EventType registered with the parser. More...

Public Member Functions

virtual void DeregisterEventType (EventType type)
 Deregister the given event type from being a valid type this parser. recognizes. More...
 
 EventParser (params EventType[] eventTypes)
 Creates a new event parser instance. More...
 
virtual EventType GetEventType (string name)
 Retrieve an Event Type by name. More...
 
virtual Apama.Event.Event Parse (string eventText)
 Parse an event string. More...
 
virtual void RegisterEventType (EventType type)
 Register the given event type as being a valid type this parser recognizes. More...
 

Static Public Member Functions

static string GetTypeName (string eventText)
 Method to extract and return the event type name from an event string. More...
 

Properties

static EventParser DefaultParser [get]
 Singleton method for retrieving the default (singleton) EventParser. More...
 

Detailed Description

Provides the functionality to parse System.String objects into Apama Apama.Event.Event objects, for any EventType registered with the parser.

The EventParser is thread-safe.

See the Apama.Event.Parser.EventType documentation for an example of how event strings may be parsed using this class

Constructor & Destructor Documentation

Apama.Event.Parser.EventParser.EventParser ( params EventType[]  eventTypes)

Creates a new event parser instance.

Parameters
eventTypesOptional parameter for automatically registering a set of initial event types with the parser.

Member Function Documentation

virtual void Apama.Event.Parser.EventParser.DeregisterEventType ( EventType  type)
virtual

Deregister the given event type from being a valid type this parser. recognizes.

Parameters
typeThe event type to parse
virtual EventType Apama.Event.Parser.EventParser.GetEventType ( string  name)
virtual

Retrieve an Event Type by name.

Parameters
nameThe name of the EventType
Returns
The EventType or null if unknown
static string Apama.Event.Parser.EventParser.GetTypeName ( string  eventText)
static

Method to extract and return the event type name from an event string.

Note that this method will NOT parse the entire event, only the name will be extracted from the eventText.

Parameters
eventTextThe event string to process
Returns
The type name or null if the name cannot be extracted
virtual Apama.Event.Event Apama.Event.Parser.EventParser.Parse ( string  eventText)
virtual

Parse an event string.

Parameters
eventTextThe string representation of the event
Returns
The resulting Event object
Exceptions
ParserRuntimeExceptionIf the event string is invalid, or if the EventType of the specified event has not been registered with this EventParser.
virtual void Apama.Event.Parser.EventParser.RegisterEventType ( EventType  type)
virtual

Register the given event type as being a valid type this parser recognizes.

Parameters
typeThe event type to parse

Property Documentation

EventParser Apama.Event.Parser.EventParser.DefaultParser
staticget

Singleton method for retrieving the default (singleton) EventParser.

Returns
The singleton EventParser instance.
Submit a bug or feature
Copyright (c) 2013-2016 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors. Use, reproduction, transfer, publication or disclosure is prohibited except as specifically provided for in your License Agreement with Software AG.