Class: RDF::Borsh::Format
- Inherits:
-
Format
- Object
- Format
- RDF::Borsh::Format
- Defined in:
- lib/rdf/borsh/format.rb
Constant Summary collapse
- MAGIC =
'RDFB'.freeze
- VERSION =
'1'.ord
- FLAGS =
0b00000111
Class Method Summary collapse
Class Method Details
.detect(sample) ⇒ Object
17 18 19 |
# File 'lib/rdf/borsh/format.rb', line 17 def self.detect(sample) sample[0..4] == [MAGIC, VERSION].pack('a4C') end |
.name ⇒ Object
15 |
# File 'lib/rdf/borsh/format.rb', line 15 def self.name; "RDF/Borsh"; end |