public static class LmsMessageConveyor.Builder
extends java.lang.Object
CommonLmsEnum
and without support of unknown LMS events:
LmsMessageConveyor lms = LmsMessageConveyor.newBuilder().build();
LmsMessageConveyor lms = LmsMessageConveyor.newBuilder()
.addLmsEnum(CommonLmsEnum.class)
.addLmsEnum(MyAppLmsEnum.class)
.build();
LmsMessageConveyor lms = LmsMessageConveyor.newBuilder()
.addLmsEnum(CommonLmsEnum.class)
.addLmsEnum(MyAppLmsEnum.class)
.allowUnknownMessages(true)
.build();
CommonLmsEnum
. If this enumeration
is not included in the list, and given custom enumeration(s) does not contain its
declarations, then "common LMS events" may be treated by this conveyor as unknown.LmsMessageConveyor.newBuilder()
Modifier and Type | Field | Description |
---|---|---|
protected java.lang.Boolean |
allowUnknownEvents |
|
protected java.util.List<java.lang.Class<?>> |
lmsEnums |
Constructor | Description |
---|---|
Builder() |
Modifier and Type | Method | Description |
---|---|---|
<E extends java.lang.Enum<E> & LmsMessageTemplate> |
addLmsEnum(java.lang.Class<E> lmsEnum) |
Adds LMS enumeration to the list of declarations for the conveyor.
It may be called several times to include several enums. Order of this method calls may be important in case, when enumerations may contain own declarations for a same event ID. In such a case, last declarations will override previously declared ones. |
LmsMessageConveyor.Builder |
allowUnknownMessages(java.lang.Boolean allowUnknownEvents) |
Enables or disables support of "unknown" messages.
This is about the case, when application tries to log event with unsupported ID. |
LmsMessageConveyor |
build() |
Creates new instance of
LmsMessageConveyor with given parameters. |
protected java.util.List<java.lang.Class<?>> lmsEnums
protected java.lang.Boolean allowUnknownEvents
public <E extends java.lang.Enum<E> & LmsMessageTemplate> LmsMessageConveyor.Builder addLmsEnum(java.lang.Class<E> lmsEnum)
lmsEnum
- the LMS enumeration class.public LmsMessageConveyor.Builder allowUnknownMessages(java.lang.Boolean allowUnknownEvents)
lmsLogger.log(43210, "internal error");
when no message ID 43210
defined in the conveyor enumeration(s) and LMS file(s).
There are following supported values for this option:FALSE
(the default value) - to throw IllegalArgumentException
on undefined events logging;TRUE
- to allow undefined events logging;null
- to skip undefined events;allowUnknownEvents
- enabling option value for the unknown events support feature.public LmsMessageConveyor build()
LmsMessageConveyor
with given parameters.Send comments on this topicTechpubs.webadmin@genesys.com.
Document version: 9.0.006.00
Copyright © 2006–2019 Genesys Telecommunications Laboratories, Inc. All rights reserved.