ruleby 0.8.b4 → 0.8.b5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/core/nodes.rb +13 -4
- metadata +3 -3
data/lib/core/nodes.rb
CHANGED
|
@@ -697,10 +697,13 @@ module Ruleby
|
|
|
697
697
|
|
|
698
698
|
def modify_left(context)
|
|
699
699
|
@left_memory[context.fact.id] = [context]
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
700
|
+
@right_memory.values.each do |right_context|
|
|
701
|
+
mr = match_ref_nodes(context,right_context)
|
|
702
|
+
if (mr.is_match)
|
|
703
|
+
new_context = MatchContext.new context.fact, mr
|
|
704
|
+
propagate_modify(new_context)
|
|
705
|
+
end
|
|
706
|
+
end
|
|
704
707
|
end
|
|
705
708
|
|
|
706
709
|
def modify_right(context)
|
|
@@ -826,6 +829,12 @@ module Ruleby
|
|
|
826
829
|
end
|
|
827
830
|
end
|
|
828
831
|
|
|
832
|
+
def modify_left(context)
|
|
833
|
+
@left_memory[context.fact.id] = context
|
|
834
|
+
|
|
835
|
+
# TODO something needs to happen here - but i'm not sure what!
|
|
836
|
+
end
|
|
837
|
+
|
|
829
838
|
# NOTE this returns a boolean, while the other classes return a MatchResult
|
|
830
839
|
def match_ref_nodes(left_context,right_context)
|
|
831
840
|
@ref_nodes.each do |ref_node|
|
metadata
CHANGED
|
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
|
5
5
|
segments:
|
|
6
6
|
- 0
|
|
7
7
|
- 8
|
|
8
|
-
-
|
|
9
|
-
version: 0.8.
|
|
8
|
+
- b5
|
|
9
|
+
version: 0.8.b5
|
|
10
10
|
platform: ruby
|
|
11
11
|
authors:
|
|
12
12
|
- Joe Kutner
|
|
@@ -15,7 +15,7 @@ autorequire:
|
|
|
15
15
|
bindir: bin
|
|
16
16
|
cert_chain: []
|
|
17
17
|
|
|
18
|
-
date: 2011-04-
|
|
18
|
+
date: 2011-04-15 00:00:00 -05:00
|
|
19
19
|
default_executable:
|
|
20
20
|
dependencies: []
|
|
21
21
|
|