}
public static BehaviorProvider<FromBehavior> getProvider() {
return new BehaviorProvider<FromBehavior>() {
public FromBehavior get(DynamicAttribute keyAttribute, Map<AttributeKey, Attribute> attributes, int line, int col) throws ExpressionParsingException, BehaviorInstantiationException {
Expression from = keyAttribute.getExpression();
AttributeKey toKey = new AttributeKey(keyAttribute.getAttributeNameSpace(), "to");
Attribute toAttribute = attributes.get(toKey);
if (toAttribute == null || !(toAttribute instanceof DynamicAttribute)) {
throw new BehaviorInstantiationException("Required parameters to is not set", line, col);
}
Expression to = ((DynamicAttribute) toAttribute).getExpression();
return new FromBehavior(from, to, line, col);
}
};
}