use of org.springframework.context.expression.MapAccessor in project spring-boot-admin by codecentric.
the class DingTalkNotifier method getText.
private Object getText(InstanceEvent event, Instance instance) {
Map<String, Object> root = new HashMap<>();
root.put("event", event);
root.put("instance", instance);
root.put("lastStatus", getLastStatus(event.getInstance()));
StandardEvaluationContext context = new StandardEvaluationContext(root);
context.addPropertyAccessor(new MapAccessor());
return message.getValue(context, String.class);
}
use of org.springframework.context.expression.MapAccessor in project spring-boot-admin by codecentric.
the class LetsChatNotifier method getText.
@Nullable
protected String getText(InstanceEvent event, Instance instance) {
Map<String, Object> root = new HashMap<>();
root.put("event", event);
root.put("instance", instance);
root.put("lastStatus", getLastStatus(event.getInstance()));
StandardEvaluationContext context = new StandardEvaluationContext(root);
context.addPropertyAccessor(new MapAccessor());
return message.getValue(context, String.class);
}
use of org.springframework.context.expression.MapAccessor in project spring-boot-admin by codecentric.
the class SlackNotifier method getText.
@Nullable
protected String getText(InstanceEvent event, Instance instance) {
Map<String, Object> root = new HashMap<>();
root.put("event", event);
root.put("instance", instance);
root.put("lastStatus", getLastStatus(event.getInstance()));
StandardEvaluationContext context = new StandardEvaluationContext(root);
context.addPropertyAccessor(new MapAccessor());
return message.getValue(context, String.class);
}
use of org.springframework.context.expression.MapAccessor in project spring-boot-admin by codecentric.
the class DiscordNotifier method createContent.
@Nullable
protected String createContent(InstanceEvent event, Instance instance) {
Map<String, Object> root = new HashMap<>();
root.put("event", event);
root.put("instance", instance);
root.put("lastStatus", getLastStatus(event.getInstance()));
StandardEvaluationContext context = new StandardEvaluationContext(root);
context.addPropertyAccessor(new MapAccessor());
return message.getValue(context, String.class);
}
use of org.springframework.context.expression.MapAccessor in project cas by apereo.
the class AbstractCasWebflowConfigurer method getSpringExpressionParser.
/**
* Gets spring expression parser.
*
* @return the spring expression parser
*/
protected SpringELExpressionParser getSpringExpressionParser() {
final SpelParserConfiguration configuration = new SpelParserConfiguration();
final SpelExpressionParser spelExpressionParser = new SpelExpressionParser(configuration);
final SpringELExpressionParser parser = new SpringELExpressionParser(spelExpressionParser, this.flowBuilderServices.getConversionService());
parser.addPropertyAccessor(new ActionPropertyAccessor());
parser.addPropertyAccessor(new BeanFactoryPropertyAccessor());
parser.addPropertyAccessor(new FlowVariablePropertyAccessor());
parser.addPropertyAccessor(new MapAdaptablePropertyAccessor());
parser.addPropertyAccessor(new MessageSourcePropertyAccessor());
parser.addPropertyAccessor(new ScopeSearchingPropertyAccessor());
parser.addPropertyAccessor(new BeanExpressionContextAccessor());
parser.addPropertyAccessor(new MapAccessor());
parser.addPropertyAccessor(new MapAdaptablePropertyAccessor());
parser.addPropertyAccessor(new EnvironmentAccessor());
parser.addPropertyAccessor(new ReflectivePropertyAccessor());
return parser;
}
Aggregations