@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName(className, LoggerContextListener.class, context); if (lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName( className, LoggerContextListener.class, context); if(lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }
@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName(className, LoggerContextListener.class, context); if (lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }
@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName(className, LoggerContextListener.class, context); if (lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }
@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName(className, LoggerContextListener.class, context); if (lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName( className, LoggerContextListener.class, context); if(lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void end(InterpretationContext ec, String name) throws ActionException { if (inError) { return; } Object o = ec.peekObject(); if (o != lcl) { addWarn("The object on the top the of the stack is not the LoggerContextListener pushed earlier."); } else { if (lcl instanceof LifeCycle) { ((LifeCycle) lcl).start(); addInfo("Starting LoggerContextListener"); } ((LoggerContext) context).addListener(lcl); ec.popObject(); } }
@Override public void begin(InterpretationContext ec, String name, Attributes attributes) throws ActionException { inError = false; String className = attributes.getValue(CLASS_ATTRIBUTE); if (OptionHelper.isEmpty(className)) { addError("Mandatory \"" + CLASS_ATTRIBUTE + "\" attribute not set for <loggerContextListener> element"); inError = true; return; } try { lcl = (LoggerContextListener) OptionHelper.instantiateByClassName( className, LoggerContextListener.class, context); if(lcl instanceof ContextAware) { ((ContextAware) lcl).setContext(context); } ec.pushObject(lcl); addInfo("Adding LoggerContextListener of type [" + className + "] to the object stack"); } catch (Exception oops) { inError = true; addError("Could not create LoggerContextListener of type " + className + "].", oops); } }