本文整理了Java中ch.qos.logback.core.joran.spi.Interpreter.getInterpretationContext()
方法的一些代码示例,展示了Interpreter.getInterpretationContext()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Interpreter.getInterpretationContext()
方法的具体详情如下:
包路径:ch.qos.logback.core.joran.spi.Interpreter
类名称:Interpreter
方法名:getInterpretationContext
暂无
代码示例来源:origin: ch.qos.logback/logback-classic
@SuppressWarnings("unchecked")
public Appender<ILoggingEvent> getAppender() {
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
HashMap<String, Appender<?>> appenderMap = (HashMap<String, Appender<?>>) omap.get(ActionConst.APPENDER_BAG);
oneAndOnlyOneCheck(appenderMap);
Collection<Appender<?>> values = appenderMap.values();
if (values.size() == 0) {
return null;
}
return (Appender<ILoggingEvent>) values.iterator().next();
}
}
代码示例来源:origin: ch.qos.logback/logback-classic
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap<String, Appender<?>>());
//omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
Map<String, String> propertiesMap = new HashMap<String, String>();
propertiesMap.putAll(parentPropertyMap);
propertiesMap.put(key, value);
interpreter.setInterpretationContextPropertiesMap(propertiesMap);
}
代码示例来源:origin: camunda/camunda-bpm-platform
/**
* @deprecated replaced by {@link #getInterpretationContext()}
*/
public InterpretationContext getExecutionContext() {
return getInterpretationContext();
}
代码示例来源:origin: camunda/camunda-bpm-platform
public InterpretationContext getInterpretationContext() {
return interpreter.getInterpretationContext();
}
}
代码示例来源:origin: camunda/camunda-bpm-platform
@SuppressWarnings("unchecked")
public Appender<ILoggingEvent> getAppender() {
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
HashMap appenderMap = (HashMap) omap.get(ActionConst.APPENDER_BAG);
oneAndOnlyOneCheck(appenderMap);
Collection values = appenderMap.values();
if(values.size() == 0) {
return null;
}
return (Appender<ILoggingEvent>) values.iterator().next();
}
}
代码示例来源:origin: camunda/camunda-bpm-platform
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext()
.getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap());
omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
}
代码示例来源:origin: camunda/camunda-bpm-platform
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap());
omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
Map<String, String> propertiesMap = new HashMap<String, String>();
propertiesMap.putAll(parentPropertyMap);
propertiesMap.put(key, value);
interpreter.setInterpretationContextPropertiesMap(propertiesMap);
}
代码示例来源:origin: camunda/camunda-bpm-platform
public void play(List<SaxEvent> aSaxEventList) {
eventList = aSaxEventList;
SaxEvent se;
for(currentIndex = 0; currentIndex < eventList.size(); currentIndex++) {
se = eventList.get(currentIndex);
if(se instanceof StartEvent) {
interpreter.startElement((StartEvent) se);
// invoke fireInPlay after startElement processing
interpreter.getInterpretationContext().fireInPlay(se);
}
if(se instanceof BodyEvent) {
// invoke fireInPlay before characters processing
interpreter.getInterpretationContext().fireInPlay(se);
interpreter.characters((BodyEvent) se);
}
if(se instanceof EndEvent) {
// invoke fireInPlay before endElement processing
interpreter.getInterpretationContext().fireInPlay(se);
interpreter.endElement((EndEvent) se);
}
}
}
代码示例来源:origin: camunda/camunda-bpm-platform
protected void buildInterpreter() {
RuleStore rs = new SimpleRuleStore(context);
addInstanceRules(rs);
this.interpreter = new Interpreter(context, rs, initialElementPath());
InterpretationContext interpretationContext = interpreter.getInterpretationContext();
interpretationContext.setContext(context);
addImplicitRules(interpreter);
addDefaultNestedComponentRegistryRules(interpretationContext.getDefaultNestedComponentRegistry());
}
代码示例来源:origin: tony19/logback-android
/**
* @deprecated replaced by {@link #getInterpretationContext()}
* @return the interpretation context of the interpreter
*/
public InterpretationContext getExecutionContext() {
return getInterpretationContext();
}
代码示例来源:origin: io.virtdata/virtdata-lib-realer
/**
* @deprecated replaced by {@link #getInterpretationContext()}
*/
public InterpretationContext getExecutionContext() {
return getInterpretationContext();
}
代码示例来源:origin: tony19/logback-android
@SuppressWarnings("unchecked")
public Appender<ILoggingEvent> getAppender() {
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
HashMap<String, Appender<?>> appenderMap = (HashMap<String, Appender<?>>) omap.get(ActionConst.APPENDER_BAG);
oneAndOnlyOneCheck(appenderMap);
Collection<Appender<?>> values = appenderMap.values();
if(values.size() == 0) {
return null;
}
return (Appender<ILoggingEvent>) values.iterator().next();
}
}
代码示例来源:origin: at.bestsolution.efxclipse.eclipse/ch.qos.logback.core
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext()
.getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap());
omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
}
代码示例来源:origin: tony19/logback-android
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext()
.getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap<String, Appender<?>>());
//omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
}
代码示例来源:origin: tony19/logback-android
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap<String, Appender<?>>());
//omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
Map<String, String> propertiesMap = new HashMap<String, String>();
propertiesMap.putAll(parentPropertyMap);
propertiesMap.put(key, value);
interpreter.setInterpretationContextPropertiesMap(propertiesMap);
}
代码示例来源:origin: ch.qos.logback/logback-access
@Override
protected void buildInterpreter() {
super.buildInterpreter();
Map<String, Object> omap = interpreter.getInterpretationContext().getObjectMap();
omap.put(ActionConst.APPENDER_BAG, new HashMap<String, Appender<IAccessEvent>>());
//omap.put(ActionConst.FILTER_CHAIN_BAG, new HashMap());
Map<String, String> propertiesMap = new HashMap<String, String>();
propertiesMap.putAll(parentPropertyMap);
propertiesMap.put(key, value);
interpreter.setInterpretationContextPropertiesMap(propertiesMap);
}
代码示例来源:origin: tony19/logback-android
@Test
public void good() throws JoranException {
simpleConfigurator.doConfigure(DEFINE_INPUT_DIR + GOOD_XML);
InterpretationContext ic = simpleConfigurator.getInterpreter().getInterpretationContext();
String inContextFoo = ic.getProperty("foo");
assertEquals("monster", inContextFoo);
}
代码示例来源:origin: tony19/logback-android
/**
* Builds a generic configuration-XML interpreter
*/
protected void buildInterpreter() {
RuleStore rs = new SimpleRuleStore(context);
addInstanceRules(rs);
this.interpreter = new Interpreter(context, rs, initialElementPath());
InterpretationContext interpretationContext = interpreter.getInterpretationContext();
interpretationContext.setContext(context);
addImplicitRules(interpreter);
addDefaultNestedComponentRegistryRules(interpretationContext.getDefaultNestedComponentRegistry());
}
代码示例来源:origin: com.alibaba.citrus.tool/antx-autoexpand
protected void buildInterpreter() {
RuleStore rs = new SimpleRuleStore(context);
addInstanceRules(rs);
this.interpreter = new Interpreter(context, rs, initialPattern());
InterpretationContext ec = interpreter.getInterpretationContext();
ec.setContext(context);
addImplicitRules(interpreter);
addDefaultNestedComponentRegistryRules(ec.getDefaultNestedComponentRegistry());
}
代码示例来源:origin: tony19/logback-android
@Override
final public void doConfigure(final List<SaxEvent> eventList)
throws JoranException {
buildInterpreter();
interpreter.getInterpretationContext().pushObject(ff);
EventPlayer player = new EventPlayer(interpreter);
player.play(eventList);
}
内容来源于网络,如有侵权,请联系作者删除!