StandardEvaluationContext sec = new StandardEvaluationContext();
sec.setRootObject(beanEvaluationContext);
sec.addPropertyAccessor(new BeanExpressionContextAccessor());
sec.addPropertyAccessor(new BeanFactoryAccessor());
sec.addPropertyAccessor(new MapAccessor());
sec.setBeanResolver(new BeanFactoryResolver(beanEvaluationContext.getBeanFactory()));
sec.setTypeLocator(new StandardTypeLocator(beanEvaluationContext.getBeanFactory().getBeanClassLoader()));
ConversionService conversionService = beanEvaluationContext.getBeanFactory().getConversionService();
if (conversionService != null) {
sec.setTypeConverter(new StandardTypeConverter(conversionService));