01: /*
02: * $Id: ExpressionEvaluator.java 11231 2008-03-06 21:17:37Z rossmason $
03: * --------------------------------------------------------------------------------------
04: * Copyright (c) MuleSource, Inc. All rights reserved. http://www.mulesource.com
05: *
06: * The software in this package is published under the terms of the CPAL v1.0
07: * license, a copy of which has been included with this distribution in the
08: * LICENSE.txt file.
09: */
10:
11: package org.mule.util.expression;
12:
13: import org.mule.api.NamedObject;
14:
15: /**
16: * <code>ExpressionEvaluator</code> extracts a property from the message in a generic
17: * way. i.e. composite properties can be pulled and aggregated depending on this
18: * strategy. This can be used to extract Correlation Ids, Message Ids etc.
19: *
20: * These objects are used to execute property expressions (usually on the
21: * current message) at runtime to extracta dynamic value.
22: */
23: public interface ExpressionEvaluator extends NamedObject {
24: /**
25: * Extracts a single property from the message
26: *
27: * @param expression the property expression or expression
28: * @param message the message to extract from
29: * @return the result of the extraction or null if the property was not found
30: */
31: Object evaluate(String expression, Object message);
32:
33: }
|