lib/openwfe/expressions/fe_raw.rb in openwferu-0.9.8 vs lib/openwfe/expressions/fe_raw.rb in openwferu-0.9.9
- old
+ new
@@ -109,11 +109,11 @@
template = lookup_variable(exp_name)
#
# is it a subprocess ?
- if (not template) and (not exp_class)
+ if ((not template) and (not exp_class))
template = get_participant_map.lookup_participant(exp_name)
unless template
exp_name = OpenWFE::to_underscore(exp_name)
@@ -145,11 +145,11 @@
expression = instantiate_real_expression(
workitem, exp_class, attributes)
expression.apply_time = OpenWFE::now()
- expression.apply(workitem)
+ expression.apply workitem
end
#
# This method is called by the expression pool when it is about
# to launch a process, it will interpret the 'parameter' statements
@@ -180,10 +180,19 @@
end
def expression_name ()
raw_representation.name
end
+
+ #
+ # Forces the raw expression to load the attributes and set them
+ # in its @attributes instance variable.
+ # Currently only used by FilterDefinitionExpression.
+ #
+ def load_attributes
+ @attributes = extract_attributes()
+ end
protected
#
# Takes care of extracting the process definition descriptions
@@ -208,23 +217,9 @@
return if ds.length < 1
set_variable "description", ds[0][1] \
unless default
end
-
- #def launch_template (template, workitem)
- # @attributes = extract_attributes()
- # params = lookup_attributes(workitem)
- # extract_text_children.each_with_index do |value, index|
- # params[index.to_s] = value
- # end
- # get_expression_pool().launch_template(
- # self,
- # get_next_sub_id,
- # template,
- # workitem,
- # params)
- #end
def extract_attributes ()
raise NotImplementedError.new("'abstract method' sorry")
end
def extract_children ()