bio-publisci 0.0.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.
Files changed (95) hide show
  1. data/.document +5 -0
  2. data/.rspec +1 -0
  3. data/.travis.yml +13 -0
  4. data/Gemfile +24 -0
  5. data/LICENSE.txt +20 -0
  6. data/README.md +47 -0
  7. data/README.rdoc +48 -0
  8. data/Rakefile +70 -0
  9. data/bin/bio-publisci +83 -0
  10. data/features/create_generator.feature +25 -0
  11. data/features/integration.feature +12 -0
  12. data/features/integration_steps.rb +10 -0
  13. data/features/orm.feature +60 -0
  14. data/features/orm_steps.rb +74 -0
  15. data/features/reader.feature +25 -0
  16. data/features/reader_steps.rb +60 -0
  17. data/features/step_definitions/bio-publisci_steps.rb +0 -0
  18. data/features/store.feature +27 -0
  19. data/features/store_steps.rb +42 -0
  20. data/features/support/env.rb +13 -0
  21. data/features/writer.feature +9 -0
  22. data/features/writer_steps.rb +17 -0
  23. data/lib/bio-publisci/analyzer.rb +57 -0
  24. data/lib/bio-publisci/dataset/ORM/data_cube_orm.rb +219 -0
  25. data/lib/bio-publisci/dataset/ORM/observation.rb +20 -0
  26. data/lib/bio-publisci/dataset/data_cube.rb +308 -0
  27. data/lib/bio-publisci/dataset/interactive.rb +57 -0
  28. data/lib/bio-publisci/loader.rb +36 -0
  29. data/lib/bio-publisci/metadata/metadata.rb +105 -0
  30. data/lib/bio-publisci/parser.rb +64 -0
  31. data/lib/bio-publisci/query/query_helper.rb +114 -0
  32. data/lib/bio-publisci/r_client.rb +54 -0
  33. data/lib/bio-publisci/readers/arff.rb +87 -0
  34. data/lib/bio-publisci/readers/big_cross.rb +119 -0
  35. data/lib/bio-publisci/readers/cross.rb +72 -0
  36. data/lib/bio-publisci/readers/csv.rb +54 -0
  37. data/lib/bio-publisci/readers/dataframe.rb +66 -0
  38. data/lib/bio-publisci/readers/r_matrix.rb +152 -0
  39. data/lib/bio-publisci/store.rb +56 -0
  40. data/lib/bio-publisci/writers/arff.rb +66 -0
  41. data/lib/bio-publisci/writers/dataframe.rb +81 -0
  42. data/lib/bio-publisci.rb +36 -0
  43. data/lib/r2rdf.rb +226 -0
  44. data/lib/template_bak/publisci.rb +3 -0
  45. data/lib/template_bak.rb +12 -0
  46. data/lib/vocabs/cc.rb +18 -0
  47. data/lib/vocabs/cert.rb +13 -0
  48. data/lib/vocabs/dc.rb +63 -0
  49. data/lib/vocabs/dc11.rb +23 -0
  50. data/lib/vocabs/doap.rb +45 -0
  51. data/lib/vocabs/exif.rb +168 -0
  52. data/lib/vocabs/foaf.rb +69 -0
  53. data/lib/vocabs/geo.rb +13 -0
  54. data/lib/vocabs/http.rb +26 -0
  55. data/lib/vocabs/ma.rb +78 -0
  56. data/lib/vocabs/owl.rb +59 -0
  57. data/lib/vocabs/rdfs.rb +17 -0
  58. data/lib/vocabs/rsa.rb +12 -0
  59. data/lib/vocabs/rss.rb +14 -0
  60. data/lib/vocabs/sioc.rb +93 -0
  61. data/lib/vocabs/skos.rb +36 -0
  62. data/lib/vocabs/wot.rb +21 -0
  63. data/lib/vocabs/xhtml.rb +9 -0
  64. data/lib/vocabs/xsd.rb +58 -0
  65. data/resources/queries/codes.rq +13 -0
  66. data/resources/queries/dataset.rq +7 -0
  67. data/resources/queries/dimension_ranges.rq +8 -0
  68. data/resources/queries/dimensions.rq +7 -0
  69. data/resources/queries/measures.rq +7 -0
  70. data/resources/queries/observations.rq +12 -0
  71. data/resources/queries/test.rq +3 -0
  72. data/resources/weather.numeric.arff +23 -0
  73. data/spec/analyzer_spec.rb +36 -0
  74. data/spec/bio-publisci_spec.rb +7 -0
  75. data/spec/csv/bacon.csv +4 -0
  76. data/spec/csv/moar_bacon.csv +11 -0
  77. data/spec/data_cube_spec.rb +166 -0
  78. data/spec/generators/csv_spec.rb +44 -0
  79. data/spec/generators/dataframe_spec.rb +44 -0
  80. data/spec/generators/r_matrix_spec.rb +35 -0
  81. data/spec/queries/integrity/1.rq +21 -0
  82. data/spec/queries/integrity/11.rq +29 -0
  83. data/spec/queries/integrity/12.rq +37 -0
  84. data/spec/queries/integrity/14.rq +25 -0
  85. data/spec/queries/integrity/19_1.rq +21 -0
  86. data/spec/queries/integrity/19_2.rq +15 -0
  87. data/spec/queries/integrity/2.rq +22 -0
  88. data/spec/queries/integrity/3.rq +19 -0
  89. data/spec/queries/integrity/4.rq +13 -0
  90. data/spec/queries/integrity/5.rq +14 -0
  91. data/spec/r_builder_spec.rb +33 -0
  92. data/spec/spec_helper.rb +17 -0
  93. data/spec/turtle/bacon +149 -0
  94. data/spec/turtle/reference +2066 -0
  95. metadata +259 -0
data/lib/r2rdf.rb ADDED
@@ -0,0 +1,226 @@
1
+ require 'rserve'
2
+ require 'rdf/4store'
3
+ Dir[File.dirname(__FILE__) + '/vocabs/*.rb'].each {|file| require file }
4
+
5
+ class QTL2RDF
6
+
7
+ attr_accessor :port_4s
8
+
9
+ def initialize(dir='.')
10
+ @dir = File.absolute_path(dir)
11
+ @R = Rserve::Connection.new()
12
+ if File.exist?(dir + "/.RData")
13
+ # puts "loading workspace #{dir}/.RData"
14
+ @R.eval("load('#{dir}/.RData')")
15
+ end
16
+
17
+ if File.exist?(dir + "/.Rhistory")
18
+ # puts "loading history #{dir}/.Rhistory"
19
+ @R.eval("loadhistory('#{dir}/.Rhistory')")
20
+ end
21
+
22
+ @port_4s = 8080
23
+ end
24
+
25
+ def load_workspace(dir=@dir,file='.RData')
26
+ path = File.join(File.absolute_path(dir),file)
27
+ if File.exist?(path)
28
+ # puts "loading workspace #{dir}/.RData"
29
+ @R.eval("load('#{path}')")
30
+ else
31
+ puts "Couldn't find #{path}"
32
+ end
33
+ end
34
+
35
+ def load_history(dir=@dir,file='.Rhistory')
36
+ path = File.join(File.absolute_path(dir),file)
37
+ if File.exist?(path)
38
+ # puts "loading history #{dir}/.Rhistory"
39
+ @R.eval("loadhistory('#{path}')")
40
+ else
41
+ puts "Couldn't find #{path}"
42
+ end
43
+ end
44
+
45
+ def dump_dataframe(var)
46
+ h = {}
47
+ h[var] = {"attr" => {}, "rows"=>{}}
48
+
49
+ x = @R.eval(var)
50
+
51
+ x.attr.payload.keys.map{ |a|
52
+ h[var]["attr"][a] = x.attr.payload[a].to_ruby
53
+ }
54
+
55
+ rownames = x.attr.payload["row.names"].to_ruby
56
+ colnames = x.payload.keys
57
+ rownames.each_with_index.map{ |row,i|
58
+ rh = {}
59
+ colnames.map{ |col|
60
+ rh[col] = x.payload[col].to_a[i].to_f
61
+ }
62
+ h[var]["rows"][row] = rh
63
+ }
64
+
65
+ h
66
+ end
67
+
68
+ def dump(var)
69
+ x = @R.eval(var)
70
+ if x.attr
71
+ # if x.attr.payload["class"].to_a.include? 'data.frame'
72
+ dump_dataframe var
73
+ # end
74
+ else
75
+ if x.list?
76
+ type = x.payload.class.to_s.split("::").last # seems hacky, but probably only temporary
77
+ value = x.payload.map(&:payload).flatten
78
+ elsif x.payload.size == 1
79
+ type = x.class.to_s.split("::").last
80
+ value = x.payload.first
81
+ else
82
+ type = x.class.to_s.split("::").last
83
+ value = x.payload
84
+ end
85
+ {var => {"attr"=>{"class" => type}, :value => value}}
86
+ end
87
+ end
88
+
89
+ def triples_for(h)
90
+ statements = []
91
+ base_n = RDF::Node.new
92
+ attr_n = RDF::Node.new
93
+ vocab = RDF::Vocabulary.new('http://www.placeholder.com/rqtl#')
94
+ base_uri = RDF::URI.new('http://www.placeholder.com/')
95
+ var = h.keys.first
96
+
97
+ statements << RDF::Statement.new(base_n, RDF::DC.title, RDF::Literal.new(var))
98
+
99
+ if h[var].is_a? Hash
100
+ if(h[var]["attr"])
101
+ statements << RDF::Statement.new(base_n, vocab.attributes, attr_n)
102
+ h[var]["attr"].map{ |k,v| statements << RDF::Statement.new(attr_n, vocab[k], RDF::Literal.new(v)) }
103
+ end
104
+
105
+ if h[var]["rows"]
106
+ h[var]["rows"].map{ |k,v|
107
+ row_uri = base_uri.join("row#{k}")
108
+ statements << RDF::Statement.new(row_uri, vocab.row_of, base_n)
109
+ statements << RDF::Statement.new(row_uri, RDF::DC.title, k)
110
+ num = 1 # maybe container support exists in RDF.rb?
111
+ v.map { |j,u|
112
+ n = RDF::Node.new
113
+ statements << RDF::Statement.new(n, vocab.entry_of, row_uri)
114
+ statements << RDF::Statement.new(n, RDF::DC.title, j)
115
+ statements << RDF::Statement.new(n, RDF::DC.title, j)
116
+ statements << RDF::Statement.new(n, vocab["_#{num}"], RDF::Literal.new(u))
117
+ num += 1
118
+ }
119
+ }
120
+ end
121
+
122
+ if h[var].has_key? :value
123
+ statements << RDF::Statement.new(base_n, vocab.has_value, RDF::Literal.new(h[var][:value]))
124
+ end
125
+ else
126
+ statements << RDF::Statement.new(base_n, vocab.has_value, RDF::Literal.new(h[var]))
127
+ end
128
+ statements
129
+ end
130
+
131
+ #get n3 for a dataframe using datacube vocabulary
132
+ #still needs range for measures and dimensions, sdmx-dimension equivalent for rows
133
+ def n3_for(h)
134
+ str = <<-EOF
135
+ @prefix : <http://www.rqtl.org/ns/#> .
136
+ @prefix qb: <http://purl.org/linked-data/cube#> .
137
+ @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
138
+ @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
139
+ @prefix prop: <http://www.rqtl.org/dc/properties/> .
140
+ @prefix cs: <http://www.rqtl.org/dc/cs/> .
141
+
142
+ EOF
143
+ #@prefix sdmx-measure: <http://purl.org/linked-data/sdmx/2009/measure#>
144
+ var = h.keys.first
145
+ names = h[var]["attr"]["names"]
146
+
147
+ #generate data structure definition
148
+ str << ":dsd-#{var} a qb:DataStructureDefinition ;\n"
149
+ str << "\tqb:component cs:refRow ,\n"
150
+ names.map{ |n|
151
+ str << "\t\tcs:#{n} ,\n\n"
152
+ }
153
+ str[-3]="."
154
+
155
+ #generate component specifications
156
+ str << "cs:refRow a qb:ComponentSpecification ;\n\trdfs:label \"Component Specification for Row\" ;\n\tqb:dimension prop:refRow .\n\n"
157
+ names.map{ |n|
158
+ str << "cs:#{n} a qb:ComponentSpecification ;\n\trdfs:label \"Component Specification for #{n}\" ;\n\tqb:measure prop:#{n} .\n\n"
159
+ }
160
+
161
+ #generate dataset definition
162
+ str << ":dataset-#{var} a qb:DataSet ;\n\trdfs:label \"#{var}\"@en ;\n\tqb:structure :dsd-#{var} .\n\n"
163
+
164
+ #add DimensionProperty for row
165
+ str << <<-EOF
166
+ :refRow a rdf:Property, qb:DimensionProperty ;
167
+ \trdfs:label "Row"@en .
168
+
169
+ EOF
170
+
171
+ #generate MeasureProperties
172
+ names.map{ |n|
173
+ str << ":#{n} a rdf:Property, qb:MeasureProperty ;\n\trdfs:label \"#{n}\"@en .\n\n"
174
+ }
175
+
176
+ #add observations
177
+ h[var]["rows"].map{|k,v|
178
+ str << ":obs#{k} a qb:Observation ;\n\tqb:dataSet :dataset-#{var} ;\n\tprop:refRow :#{k} ;\n"
179
+ v.map{|l,w|
180
+ str << "\tprop:#{l} #{w} ;\n"
181
+ }
182
+ str << "\t.\n\n"
183
+ }
184
+
185
+ #add row property definitions
186
+ h[var]["rows"].map{|k,v|
187
+ str << ":#{k} a prop:refRow ;\n\trdfs:label \"#{k}\" .\n\n"
188
+ }
189
+
190
+ str
191
+ end
192
+
193
+ def statements_for(string,type=:turtle)
194
+ statements = []
195
+ RDF::Reader.for(:turtle).new(string) do |reader|
196
+ reader.each_statement do |statement|
197
+ # puts statement.inspect
198
+ statements << statement
199
+ end
200
+ end
201
+ statements
202
+ end
203
+
204
+ def turtletype_for(value)
205
+ #use for providing ranges to better define data (later)
206
+ end
207
+
208
+ def load_statements(statements)
209
+ #maybe a better way than inserting statements one at a time?
210
+ repo = RDF::FourStore::Repository.new("http://localhost:#{@port_4s}")
211
+ statements.each{|s| repo.insert(s)}
212
+ end
213
+
214
+ def to_store(var, parse_type=:turtle)
215
+ load_statements(triples_for(dump(var))) if parse_type==:ntriples
216
+
217
+ #TODO: this doesn't work (needs to be converted to statments or
218
+ # a way of inserting raw strings needs to be figured out.
219
+ load_statements(n3_for(dump(var))) if parse_type==:turtle
220
+ end
221
+
222
+ def vars
223
+ @R.eval("ls()").payload
224
+ end
225
+
226
+ end
@@ -0,0 +1,3 @@
1
+
2
+ module BioPublisci
3
+ end
@@ -0,0 +1,12 @@
1
+ # Please require your code below, respecting the naming conventions in the
2
+ # bioruby directory tree.
3
+ #
4
+ # For example, say you have a plugin named bio-plugin, the only uncommented
5
+ # line in this file would be
6
+ #
7
+ # require 'bio/bio-plugin/plugin'
8
+ #
9
+ # In this file only require other files. Avoid other source code.
10
+
11
+ require 'bio-publisci/publisci.rb'
12
+
data/lib/vocabs/cc.rb ADDED
@@ -0,0 +1,18 @@
1
+ module RDF
2
+ ##
3
+ # Creative Commons (CC) vocabulary.
4
+ #
5
+ # @see http://creativecommons.org/ns
6
+ class CC < Vocabulary("http://creativecommons.org/ns#")
7
+ property :attributionName
8
+ property :attributionURL
9
+ property :deprecatedOn
10
+ property :jurisdiction
11
+ property :legalcode
12
+ property :license
13
+ property :morePermissions
14
+ property :permits
15
+ property :prohibits
16
+ property :requires
17
+ end
18
+ end
@@ -0,0 +1,13 @@
1
+ module RDF
2
+ ##
3
+ # W3 Authentication Certificates (CERT) vocabulary.
4
+ #
5
+ # @see http://www.w3.org/ns/auth/cert#
6
+ # @since 0.2.0
7
+ class CERT < Vocabulary("http://www.w3.org/ns/auth/cert#")
8
+ property :decimal
9
+ property :hex
10
+ property :identity
11
+ property :public_key
12
+ end
13
+ end
data/lib/vocabs/dc.rb ADDED
@@ -0,0 +1,63 @@
1
+ module RDF
2
+ ##
3
+ # Dublin Core (DC) vocabulary.
4
+ #
5
+ # @see http://dublincore.org/schemas/rdfs/
6
+ class DC < Vocabulary("http://purl.org/dc/terms/")
7
+ property :abstract
8
+ property :accessRights
9
+ property :accrualMethod
10
+ property :accrualPeriodicity
11
+ property :accrualPolicy
12
+ property :alternative
13
+ property :audience
14
+ property :available
15
+ property :bibliographicCitation
16
+ property :conformsTo
17
+ property :contributor
18
+ property :coverage
19
+ property :created
20
+ property :creator
21
+ property :date
22
+ property :dateAccepted
23
+ property :dateCopyrighted
24
+ property :dateSubmitted
25
+ property :description
26
+ property :educationLevel
27
+ property :extent
28
+ property :format
29
+ property :hasFormat
30
+ property :hasPart
31
+ property :hasVersion
32
+ property :identifier
33
+ property :instructionalMethod
34
+ property :isFormatOf
35
+ property :isPartOf
36
+ property :isReferencedBy
37
+ property :isReplacedBy
38
+ property :isRequiredBy
39
+ property :isVersionOf
40
+ property :issued
41
+ property :language
42
+ property :license
43
+ property :mediator
44
+ property :medium
45
+ property :modified
46
+ property :provenance
47
+ property :publisher
48
+ property :references
49
+ property :relation
50
+ property :replaces
51
+ property :requires
52
+ property :rights
53
+ property :rightsHolder
54
+ property :source
55
+ property :spatial
56
+ property :subject
57
+ property :tableOfContents
58
+ property :temporal
59
+ property :title
60
+ property :type
61
+ property :valid
62
+ end
63
+ end
@@ -0,0 +1,23 @@
1
+ module RDF
2
+ ##
3
+ # Dublin Core (DC) legacy vocabulary.
4
+ #
5
+ # @see http://dublincore.org/schemas/rdfs/
6
+ class DC11 < Vocabulary("http://purl.org/dc/elements/1.1/")
7
+ property :contributor
8
+ property :coverage
9
+ property :creator
10
+ property :date
11
+ property :description
12
+ property :format
13
+ property :identifier
14
+ property :language
15
+ property :publisher
16
+ property :relation
17
+ property :rights
18
+ property :source
19
+ property :subject
20
+ property :title
21
+ property :type
22
+ end
23
+ end
@@ -0,0 +1,45 @@
1
+ module RDF
2
+ ##
3
+ # Description of a Project (DOAP) vocabulary.
4
+ #
5
+ # @see http://trac.usefulinc.com/doap
6
+ class DOAP < Vocabulary("http://usefulinc.com/ns/doap#")
7
+ property :'anon-root'
8
+ property :audience
9
+ property :blog
10
+ property :browse
11
+ property :'bug-database'
12
+ property :category
13
+ property :created
14
+ property :description
15
+ property :developer
16
+ property :documenter
17
+ property :'download-mirror'
18
+ property :'download-page'
19
+ property :'file-release'
20
+ property :helper
21
+ property :homepage
22
+ property :implements
23
+ property :language
24
+ property :license
25
+ property :location
26
+ property :'mailing-list'
27
+ property :maintainer
28
+ property :module
29
+ property :name
30
+ property :'old-homepage'
31
+ property :os
32
+ property :platform
33
+ property :'programming-language'
34
+ property :release
35
+ property :repository
36
+ property :revision
37
+ property :screenshots
38
+ property :'service-endpoint'
39
+ property :shortdesc
40
+ property :tester
41
+ property :translator
42
+ property :vendor
43
+ property :wiki
44
+ end
45
+ end
@@ -0,0 +1,168 @@
1
+ module RDF
2
+ ##
3
+ # Exchangeable Image File Format (EXIF) vocabulary.
4
+ #
5
+ # @see http://www.w3.org/2003/12/exif/
6
+ class EXIF < Vocabulary("http://www.w3.org/2003/12/exif/ns#")
7
+ property :_unknown
8
+ property :apertureValue
9
+ property :artist
10
+ property :bitsPerSample
11
+ property :brightnessValue
12
+ property :cfaPattern
13
+ property :colorSpace
14
+ property :componentsConfiguration
15
+ property :compressedBitsPerPixel
16
+ property :compression
17
+ property :contrast
18
+ property :copyright
19
+ property :customRendered
20
+ property :datatype
21
+ property :date
22
+ property :dateAndOrTime
23
+ property :dateTime
24
+ property :dateTimeDigitized
25
+ property :dateTimeOriginal
26
+ property :deviceSettingDescription
27
+ property :digitalZoomRatio
28
+ property :exifAttribute
29
+ property :exifVersion
30
+ property :exif_IFD_Pointer
31
+ property :exifdata
32
+ property :exposureBiasValue
33
+ property :exposureIndex
34
+ property :exposureMode
35
+ property :exposureProgram
36
+ property :exposureTime
37
+ property :fNumber
38
+ property :fileSource
39
+ property :flash
40
+ property :flashEnergy
41
+ property :flashpixVersion
42
+ property :focalLength
43
+ property :focalLengthIn35mmFilm
44
+ property :focalPlaneResolutionUnit
45
+ property :focalPlaneXResolution
46
+ property :focalPlaneYResolution
47
+ property :gainControl
48
+ property :geo
49
+ property :gpsAltitude
50
+ property :gpsAltitudeRef
51
+ property :gpsAreaInformation
52
+ property :gpsDOP
53
+ property :gpsDateStamp
54
+ property :gpsDestBearing
55
+ property :gpsDestBearingRef
56
+ property :gpsDestDistance
57
+ property :gpsDestDistanceRef
58
+ property :gpsDestLatitude
59
+ property :gpsDestLatitudeRef
60
+ property :gpsDestLongitude
61
+ property :gpsDestLongitudeRef
62
+ property :gpsDifferential
63
+ property :gpsImgDirection
64
+ property :gpsImgDirectionRef
65
+ property :gpsInfo
66
+ property :gpsInfo_IFD_Pointer
67
+ property :gpsLatitude
68
+ property :gpsLatitudeRef
69
+ property :gpsLongitude
70
+ property :gpsLongitudeRef
71
+ property :gpsMapDatum
72
+ property :gpsMeasureMode
73
+ property :gpsProcessingMethod
74
+ property :gpsSatellites
75
+ property :gpsSpeed
76
+ property :gpsSpeedRef
77
+ property :gpsStatus
78
+ property :gpsTimeStamp
79
+ property :gpsTrack
80
+ property :gpsTrackRef
81
+ property :gpsVersionID
82
+ property :height
83
+ property :ifdPointer
84
+ property :imageConfig
85
+ property :imageDataCharacter
86
+ property :imageDataStruct
87
+ property :imageDescription
88
+ property :imageLength
89
+ property :imageUniqueID
90
+ property :imageWidth
91
+ property :interopInfo
92
+ property :interoperabilityIndex
93
+ property :interoperabilityVersion
94
+ property :interoperability_IFD_Pointer
95
+ property :isoSpeedRatings
96
+ property :jpegInterchangeFormat
97
+ property :jpegInterchangeFormatLength
98
+ property :length
99
+ property :lightSource
100
+ property :make
101
+ property :makerNote
102
+ property :maxApertureValue
103
+ property :meter
104
+ property :meteringMode
105
+ property :mm
106
+ property :model
107
+ property :oecf
108
+ property :orientation
109
+ property :photometricInterpretation
110
+ property :pictTaking
111
+ property :pimBrightness
112
+ property :pimColorBalance
113
+ property :pimContrast
114
+ property :pimInfo
115
+ property :pimSaturation
116
+ property :pimSharpness
117
+ property :pixelXDimension
118
+ property :pixelYDimension
119
+ property :planarConfiguration
120
+ property :primaryChromaticities
121
+ property :printImageMatching_IFD_Pointer
122
+ property :recOffset
123
+ property :referenceBlackWhite
124
+ property :relatedFile
125
+ property :relatedImageFileFormat
126
+ property :relatedImageLength
127
+ property :relatedImageWidth
128
+ property :relatedSoundFile
129
+ property :resolution
130
+ property :resolutionUnit
131
+ property :rowsPerStrip
132
+ property :samplesPerPixel
133
+ property :saturation
134
+ property :sceneCaptureType
135
+ property :sceneType
136
+ property :seconds
137
+ property :sensingMethod
138
+ property :sharpness
139
+ property :shutterSpeedValue
140
+ property :software
141
+ property :spatialFrequencyResponse
142
+ property :spectralSensitivity
143
+ property :stripByteCounts
144
+ property :stripOffsets
145
+ property :subSecTime
146
+ property :subSecTimeDigitized
147
+ property :subSecTimeOriginal
148
+ property :subjectArea
149
+ property :subjectDistance
150
+ property :subjectDistanceRange
151
+ property :subjectLocation
152
+ property :subseconds
153
+ property :tag_number
154
+ property :tagid
155
+ property :transferFunction
156
+ property :userComment
157
+ property :userInfo
158
+ property :versionInfo
159
+ property :whiteBalance
160
+ property :whitePoint
161
+ property :width
162
+ property :xResolution
163
+ property :yCbCrCoefficients
164
+ property :yCbCrPositioning
165
+ property :yCbCrSubSampling
166
+ property :yResolution
167
+ end
168
+ end
@@ -0,0 +1,69 @@
1
+ module RDF
2
+ ##
3
+ # Friend of a Friend (FOAF) vocabulary.
4
+ #
5
+ # @see http://xmlns.com/foaf/spec/
6
+ class FOAF < Vocabulary("http://xmlns.com/foaf/0.1/")
7
+ property :account
8
+ property :accountName
9
+ property :accountServiceHomepage
10
+ property :age
11
+ property :aimChatID
12
+ property :based_near
13
+ property :birthday
14
+ property :currentProject
15
+ property :depiction
16
+ property :depicts
17
+ property :dnaChecksum
18
+ property :familyName
19
+ property :family_name
20
+ property :firstName
21
+ property :fundedBy
22
+ property :geekcode
23
+ property :gender
24
+ property :givenName
25
+ property :givenname
26
+ property :holdsAccount
27
+ property :homepage
28
+ property :icqChatID
29
+ property :img
30
+ property :interest
31
+ property :isPrimaryTopicOf
32
+ property :jabberID
33
+ property :knows
34
+ property :lastName
35
+ property :logo
36
+ property :made
37
+ property :maker
38
+ property :mbox
39
+ property :mbox_sha1sum
40
+ property :member
41
+ property :membershipClass
42
+ property :msnChatID
43
+ property :myersBriggs
44
+ property :name
45
+ property :nick
46
+ property :openid
47
+ property :page
48
+ property :pastProject
49
+ property :phone
50
+ property :plan
51
+ property :primaryTopic
52
+ property :publications
53
+ property :schoolHomepage
54
+ property :sha1
55
+ property :skypeID
56
+ property :status
57
+ property :surname
58
+ property :theme
59
+ property :thumbnail
60
+ property :tipjar
61
+ property :title
62
+ property :topic
63
+ property :topic_interest
64
+ property :weblog
65
+ property :workInfoHomepage
66
+ property :workplaceHomepage
67
+ property :yahooChatID
68
+ end
69
+ end
data/lib/vocabs/geo.rb ADDED
@@ -0,0 +1,13 @@
1
+ module RDF
2
+ ##
3
+ # WGS84 Geo Positioning (GEO) vocabulary.
4
+ #
5
+ # @see http://www.w3.org/2003/01/geo/wgs84_pos#
6
+ # @since 0.2.0
7
+ class GEO < Vocabulary("http://www.w3.org/2003/01/geo/wgs84_pos#")
8
+ property :lat
9
+ property :location
10
+ property :long
11
+ property :lat_long
12
+ end
13
+ end
@@ -0,0 +1,26 @@
1
+ module RDF
2
+ ##
3
+ # Hypertext Transfer Protocol (HTTP) vocabulary.
4
+ #
5
+ # @see http://www.w3.org/2006/http
6
+ class HTTP < Vocabulary("http://www.w3.org/2006/http#")
7
+ property :abs_path
8
+ property :absoluteURI
9
+ property :authority
10
+ property :body
11
+ property :connectionAuthority
12
+ property :elementName
13
+ property :elementValue
14
+ property :fieldName
15
+ property :fieldValue
16
+ property :header
17
+ property :param
18
+ property :paramName
19
+ property :paramValue
20
+ property :request
21
+ property :requestURI
22
+ property :response
23
+ property :responseCode
24
+ property :version
25
+ end
26
+ end