cirrocumulus 0.2.3 → 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/cirrocumulus.gemspec +2 -2
- data/lib/cirrocumulus.rb +1 -1
- data/lib/cirrocumulus/engine.rb +3 -0
- data/lib/cirrocumulus/master_agent.rb +1 -1
- metadata +4 -4
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.6
|
data/cirrocumulus.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{cirrocumulus}
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.6"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Anton Kosyakin"]
|
12
|
-
s.date = %q{2011-09-
|
12
|
+
s.date = %q{2011-09-27}
|
13
13
|
s.description = %q{Engine for building your own agents, providing you base functionality for loading ontologies, communicating with other agents and parsing FIPA-ACL messages}
|
14
14
|
s.email = %q{deil@mneko.net}
|
15
15
|
s.extra_rdoc_files = [
|
data/lib/cirrocumulus.rb
CHANGED
data/lib/cirrocumulus/engine.rb
CHANGED
@@ -129,7 +129,10 @@ class Cirrocumulus
|
|
129
129
|
msg.in_reply_to = xml['in_reply_to']
|
130
130
|
msg.ontology = ontology
|
131
131
|
flatten_message_content(msg)
|
132
|
+
Log4r::Logger['cirrocumulus'].debug(msg.inspect)
|
132
133
|
agent.handle_message(msg, kb)
|
134
|
+
else
|
135
|
+
Log4r::Logger['cirrocumulus'].debug("unhandled ontology %s" % [ontology])
|
133
136
|
end
|
134
137
|
rescue Exception => e
|
135
138
|
puts e.to_s
|
@@ -186,7 +186,7 @@ module Agent
|
|
186
186
|
|
187
187
|
def handle_message(message, kb)
|
188
188
|
@network_map.handle_message(message, @cm)
|
189
|
-
self.ontologies.each {|ontology| ontology.handle_incoming_message(message, kb) if message.ontology == ontology.name}
|
189
|
+
self.ontologies.each {|ontology| ontology.handle_incoming_message(message, kb) or return if message.ontology == ontology.name} # return from loop if message was handled; 'or' is correct
|
190
190
|
rescue Exception => e
|
191
191
|
Log4r::Logger['agent'].warn "failed to handle incoming message: %s" % e.to_s
|
192
192
|
puts e.backtrace.to_s
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cirrocumulus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 27
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 2
|
9
|
-
-
|
10
|
-
version: 0.2.
|
9
|
+
- 6
|
10
|
+
version: 0.2.6
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Anton Kosyakin
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-09-
|
18
|
+
date: 2011-09-27 00:00:00 +04:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|