mascot-mgf 0.2.0 → 0.2.1
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/mascot/mgf/query.rb +1 -1
- data/lib/mascot/mgf/version.rb +1 -1
- data/lib/mascot/mgf.rb +7 -7
- metadata +5 -14
data/lib/mascot/mgf/query.rb
CHANGED
data/lib/mascot/mgf/version.rb
CHANGED
data/lib/mascot/mgf.rb
CHANGED
|
@@ -13,9 +13,9 @@ module Mascot
|
|
|
13
13
|
|
|
14
14
|
def rewind
|
|
15
15
|
super
|
|
16
|
-
@curr_index = 0
|
|
16
|
+
@curr_index = 0
|
|
17
17
|
end
|
|
18
|
-
|
|
18
|
+
|
|
19
19
|
def readquery(n=nil)
|
|
20
20
|
if n
|
|
21
21
|
@curr_index = n
|
|
@@ -25,15 +25,15 @@ module Mascot
|
|
|
25
25
|
@curr_index += 1
|
|
26
26
|
self.read(bytelength)
|
|
27
27
|
end
|
|
28
|
-
|
|
28
|
+
|
|
29
29
|
def each_query
|
|
30
30
|
while !self.eof?
|
|
31
31
|
yield self.query() if block_given?
|
|
32
32
|
end
|
|
33
33
|
end
|
|
34
34
|
|
|
35
|
-
# alias_method :io_each, :each
|
|
36
|
-
# def each
|
|
35
|
+
# alias_method :io_each, :each
|
|
36
|
+
# def each
|
|
37
37
|
# while !self.eof?
|
|
38
38
|
# yield self.readquery if block_given?
|
|
39
39
|
# end
|
|
@@ -42,7 +42,7 @@ module Mascot
|
|
|
42
42
|
def query(n=nil)
|
|
43
43
|
Mascot::MGF::Query.new(self.readquery(n))
|
|
44
44
|
end
|
|
45
|
-
|
|
45
|
+
|
|
46
46
|
# reports how many queries are in this MGF file
|
|
47
47
|
def query_count()
|
|
48
48
|
return @idx.length
|
|
@@ -73,7 +73,7 @@ module Mascot
|
|
|
73
73
|
when "END"
|
|
74
74
|
@idx[-1][1] = self.pos
|
|
75
75
|
end
|
|
76
|
-
end
|
|
76
|
+
end
|
|
77
77
|
if @cache_index
|
|
78
78
|
idx_file = File.open(@full_path + ".idx",'wb')
|
|
79
79
|
idx_file.print(::Marshal.dump(@idx))
|
metadata
CHANGED
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mascot-mgf
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
prerelease:
|
|
5
|
-
|
|
6
|
-
- 0
|
|
7
|
-
- 2
|
|
8
|
-
- 0
|
|
9
|
-
version: 0.2.0
|
|
4
|
+
prerelease:
|
|
5
|
+
version: 0.2.1
|
|
10
6
|
platform: ruby
|
|
11
7
|
authors:
|
|
12
8
|
- Angel Pizarro
|
|
@@ -14,8 +10,7 @@ autorequire:
|
|
|
14
10
|
bindir: bin
|
|
15
11
|
cert_chain: []
|
|
16
12
|
|
|
17
|
-
date: 2011-
|
|
18
|
-
default_executable:
|
|
13
|
+
date: 2011-05-13 00:00:00 Z
|
|
19
14
|
dependencies: []
|
|
20
15
|
|
|
21
16
|
description: A parser for Mascot Generic Format (MGF) files
|
|
@@ -42,7 +37,6 @@ files:
|
|
|
42
37
|
- test/fixtures/tenth_query.mgf
|
|
43
38
|
- test/fixtures/titles.yml
|
|
44
39
|
- test/test_mascot-mgf.rb
|
|
45
|
-
has_rdoc: true
|
|
46
40
|
homepage: https://github.com/delagoya/mascot-mgf
|
|
47
41
|
licenses: []
|
|
48
42
|
|
|
@@ -56,21 +50,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
56
50
|
requirements:
|
|
57
51
|
- - ">="
|
|
58
52
|
- !ruby/object:Gem::Version
|
|
59
|
-
segments:
|
|
60
|
-
- 0
|
|
61
53
|
version: "0"
|
|
62
54
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
63
55
|
none: false
|
|
64
56
|
requirements:
|
|
65
57
|
- - ">="
|
|
66
58
|
- !ruby/object:Gem::Version
|
|
67
|
-
segments:
|
|
68
|
-
- 0
|
|
69
59
|
version: "0"
|
|
70
60
|
requirements: []
|
|
71
61
|
|
|
72
62
|
rubyforge_project:
|
|
73
|
-
rubygems_version: 1.
|
|
63
|
+
rubygems_version: 1.7.2
|
|
74
64
|
signing_key:
|
|
75
65
|
specification_version: 3
|
|
76
66
|
summary: A parser for Mascot Generic Format (MGF) files
|
|
@@ -81,3 +71,4 @@ test_files:
|
|
|
81
71
|
- test/fixtures/tenth_query.mgf
|
|
82
72
|
- test/fixtures/titles.yml
|
|
83
73
|
- test/test_mascot-mgf.rb
|
|
74
|
+
has_rdoc:
|