meteor 0.9.31 → 0.9.32
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.
- checksums.yaml +4 -4
- data/ChangeLog +4 -0
- data/Gemfile.lock +1 -1
- data/demo/xhtml.rb +3 -3
- data/demo/xhtml4.rb +3 -3
- data/lib/meteor/attribute_map.rb +6 -6
- data/lib/meteor/core/kernel.rb +150 -150
- data/lib/meteor/core/util/pattern_cache.rb +6 -6
- data/lib/meteor/element.rb +10 -10
- data/lib/meteor/exception/no_such_element_exception.rb +15 -15
- data/lib/meteor/ml/html/parser_impl.rb +14 -14
- data/lib/meteor/ml/html4/parser_impl.rb +49 -49
- data/lib/meteor/ml/xhtml/parser_impl.rb +14 -14
- data/lib/meteor/ml/xhtml4/parser_impl.rb +15 -15
- data/lib/meteor/ml/xml/parser_impl.rb +6 -6
- data/lib/meteor/parsers.rb +43 -43
- data/lib/meteor.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 38acec4e07ce5a63eb73cd6492d4caa5afc394069bce3f23ce51764a3c61dd3f
|
|
4
|
+
data.tar.gz: c75abe853ec35ba1b33d4c3500860e6383d950c5600b106b1fe2d99ef7127604
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: '009a77b50208303a8b9a5ca029a3604fc8a0672d4c73cb09a589aeca30ce5d4525fa013fe928698715ba1cafe0e8f12043d4d457c20948cc87993a63fc8393b2'
|
|
7
|
+
data.tar.gz: 8c0015e1995e0e3ef2172c3489d1860978bc0202e678fa63b6d1a4c0d0ed8b315f737d0814dc05bff2a9f4033549687a52160ed6c8cba5ec9d1d20cc5a68d717
|
data/ChangeLog
CHANGED
data/Gemfile.lock
CHANGED
data/demo/xhtml.rb
CHANGED
|
@@ -8,7 +8,7 @@ require 'meteor'
|
|
|
8
8
|
Meteor::Elements.add(:xhtml, 'ml/sample_xhtml.html')
|
|
9
9
|
root = Meteor::Elements.get('/ml/sample_xhtml')
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
start_time = Time.new.to_f
|
|
12
12
|
|
|
13
13
|
elm_hello = root.element(id: 'hello')
|
|
14
14
|
# elm_hello.attr(class: "red")
|
|
@@ -85,11 +85,11 @@ end
|
|
|
85
85
|
|
|
86
86
|
root.flash
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
end_time = Time.new.to_f
|
|
89
89
|
|
|
90
90
|
puts(root.document)
|
|
91
91
|
|
|
92
92
|
puts("charset:#{root.charset}")
|
|
93
93
|
puts("content-type:#{root.content_type}")
|
|
94
94
|
|
|
95
|
-
puts("#{
|
|
95
|
+
puts("#{end_time - start_time} sec")
|
data/demo/xhtml4.rb
CHANGED
|
@@ -8,7 +8,7 @@ require 'meteor'
|
|
|
8
8
|
Meteor::Elements.add(:xhtml4, 'ml/sample_xhtml4.html', 'UTF-8')
|
|
9
9
|
root = Meteor::Elements.get('/ml/sample_xhtml4')
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
start_time = Time.new.to_f
|
|
12
12
|
|
|
13
13
|
elm_hello = root.element('id', 'hello')
|
|
14
14
|
# elm_hello.attr(class: "red")
|
|
@@ -82,11 +82,11 @@ end
|
|
|
82
82
|
|
|
83
83
|
root.flash
|
|
84
84
|
|
|
85
|
-
|
|
85
|
+
end_time = Time.new.to_f
|
|
86
86
|
|
|
87
87
|
puts(root.document)
|
|
88
88
|
|
|
89
89
|
puts("charset:#{root.charset}")
|
|
90
90
|
puts("content-type:#{root.content_type}")
|
|
91
91
|
|
|
92
|
-
puts("#{
|
|
92
|
+
puts("#{end_time - start_time} sec")
|
data/lib/meteor/attribute_map.rb
CHANGED
|
@@ -15,9 +15,9 @@ module Meteor
|
|
|
15
15
|
def initialize(*args)
|
|
16
16
|
case args.length
|
|
17
17
|
when ZERO
|
|
18
|
-
|
|
18
|
+
initialize_zero
|
|
19
19
|
when ONE
|
|
20
|
-
|
|
20
|
+
initialize_one(args[0])
|
|
21
21
|
else
|
|
22
22
|
raise ArgumentError
|
|
23
23
|
end
|
|
@@ -26,24 +26,24 @@ module Meteor
|
|
|
26
26
|
#
|
|
27
27
|
# initializer (イニシャライザ)
|
|
28
28
|
#
|
|
29
|
-
def
|
|
29
|
+
def initialize_zero
|
|
30
30
|
@map = {}
|
|
31
31
|
@recordable = false
|
|
32
32
|
end
|
|
33
33
|
|
|
34
|
-
private :
|
|
34
|
+
private :initialize_zero
|
|
35
35
|
|
|
36
36
|
#
|
|
37
37
|
# initializer (イニシャライザ)
|
|
38
38
|
# @param [Meteor::AttributeMap] attr_map attribute map (属性マップ)
|
|
39
39
|
#
|
|
40
|
-
def
|
|
40
|
+
def initialize_one(attr_map)
|
|
41
41
|
# @map = Marshal.load(Marshal.dump(attr_map.map))
|
|
42
42
|
@map = attr_map.map.dup
|
|
43
43
|
@recordable = attr_map.recordable
|
|
44
44
|
end
|
|
45
45
|
|
|
46
|
-
private :
|
|
46
|
+
private :initialize_one
|
|
47
47
|
|
|
48
48
|
#
|
|
49
49
|
# set a couple of attribute name and attribute value (属性名と属性値を対としてセットする)
|