public class EventFilter extends Object
EventID
Constructor and Description |
---|
EventFilter()
The constructor creates a buffer with all possible events set
to default (i.e.
|
EventFilter(boolean enableAll)
The constructor creates a buffer with all possible events set
to default (i.e.
|
Modifier and Type | Method and Description |
---|---|
static void |
createGlobalEventFilter()
This method is called when the event manager is created.
|
int |
getLoggedEventIndex(int id)
Gets the event logging for a event index.
|
static int |
getLoggingEvent(EventFilter filter,
int eventIndex)
Checks if an event is logged for a particular event index.
|
boolean |
isEventLogged(int eventID)
Checks if an event is logged or not for the current client connection.
|
static boolean |
isGlobalEventIndexLogged(int id)
Checks if a global event index is to be logged.
|
static boolean |
isGlobalEventLogged(int eventID)
Checks if a global event is to be logged.
|
static int |
performEventCommand(String command,
EventFilter globalFilter)
Processes a command either from a command line, (remote) console or
event filter commands in SERVER.INI.
|
static int |
performEventCommand(String eventID,
int include,
long[] clientIDs,
EventFilter globalFilter)
Processes a single eventID specification.
|
static boolean |
setupClientEvent(EventFilter filter,
int eventIndex,
int include)
Sets up the client event for the event filter data.
|
public EventFilter()
public EventFilter(boolean enableAll)
public static void createGlobalEventFilter()
public static boolean isGlobalEventLogged(int eventID)
public static boolean isGlobalEventIndexLogged(int id)
public boolean isEventLogged(int eventID)
public int getLoggedEventIndex(int id)
public static int performEventCommand(String command, EventFilter globalFilter) throws ParseException, NumberFormatException
. EventFilter --+--+-- ALL --+-- [INCLUDE:event_id] -- [EXCLUDE:event_id] -- [DEFAULT:event_id] . | | | . | +-- client_id --+ . | | . +----- , -----------+where client_id can be a comma-separated (no spaces in between) list of several client_ids,
and event_id is a comma-separated list (no spaces in between) of eventIDs as defined in SERVER.PHM and/or a range of eventIDs and/or using the '*' wildcard to accept any eventID starting with the text preceeding the '*'.
To specify all events, use the event range string "*-*".
Note that the command "EventFilter ALL DEFAULT:nnn" will never return other values than zero, because the "ALL" indicates the default setting for all clients.
ParseException
- When the command in SERVER.INI are invalid.NumberFormatException
- When a clientID is wrong.public static int performEventCommand(String eventID, int include, long[] clientIDs, EventFilter globalFilter)
The eventID is an eventID as defined in SERVER.PHM or a range of eventIDs and/or using the '*' wildcard to accept any eventID starting with the text preceeding the '*'. The range separator is '-'.
The value "include" must be zero or one for a global filter and can be zero=exclude, one=include, 2=default (use global filter).
public static boolean setupClientEvent(EventFilter filter, int eventIndex, int include)
The value "include" must be zero or one for a global filter and can be zero=exclude, one=include, 2=default (use global filter).
public static int getLoggingEvent(EventFilter filter, int eventIndex)
If filter is null, the global setting will be returned.
The return value will be -1 if the eventID is not found or for invalid parameters.
Phantom® and NetPhantom® are registered trademarks of Mindus SARL.
© © Mindus SARL, 2024. All rights reserved.