Class: Pubid::Xsf::UrnParser
- Inherits:
-
UrnParser::Base
- Object
- UrnParser::Base
- Pubid::Xsf::UrnParser
- Defined in:
- lib/pubid/xsf/urn_parser.rb
Overview
Parses XSF URNs back into identifiers.
UrnGenerator emits: urn:xsf:xep:<number> (e.g. urn:xsf:xep:0001).
This inverts it by reconstructing the printed "XEP
Instance Method Summary collapse
Methods inherited from UrnParser::Base
Instance Method Details
#parse_urn(urn) ⇒ Object
11 12 13 14 15 |
# File 'lib/pubid/xsf/urn_parser.rb', line 11 def parse_urn(urn) body = strip_namespace(urn) _type, number = split_parts(body) flavor_parse("XEP #{number}") end |