if (indexDot != -1)
{
String stream = prop.getPropertyName().substring(0, indexDot);
String property = prop.getPropertyName().substring(indexDot + 1, prop.getPropertyName().length());
VariableMetaData variableMetaData = mapContext.getVariableService().getVariableMetaData(stream);
if (variableMetaData != null)
{
mapContext.setHasVariables(true);
ExprVariableNodeImpl node = new ExprVariableNodeImpl(variableMetaData, property);
mapContext.getVariableNames().add(variableMetaData.getVariableName());
String message = VariableServiceUtil.checkVariableContextName(mapContext.getContextName(), variableMetaData);
if (message != null) {
throw new EPException(message);
}
return node;
}
if (mapContext.getContextName() != null) {
com.espertech.esper.core.context.util.ContextDescriptor contextDescriptor = mapContext.getContextManagementService().getContextDescriptor(mapContext.getContextName());
if (contextDescriptor != null && contextDescriptor.getContextPropertyRegistry().isContextPropertyPrefix(stream)) {
return new ExprContextPropertyNode(property);
}
}
return new ExprIdentNodeImpl(property, stream);
}
VariableMetaData variableMetaData = mapContext.getVariableService().getVariableMetaData(prop.getPropertyName());
if (variableMetaData != null)
{
mapContext.setHasVariables(true);
ExprVariableNodeImpl node = new ExprVariableNodeImpl(variableMetaData, null);
mapContext.getVariableNames().add(variableMetaData.getVariableName());
String message = VariableServiceUtil.checkVariableContextName(mapContext.getContextName(), variableMetaData);
if (message != null) {
throw new EPException(message);
}
return node;