Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

Commit

Permalink
Only support AKN3 namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
longhotsummer committed Jun 12, 2020
1 parent 3fdb43f commit 79bc01c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,12 @@ You can create your own grammar by creating a gem that provides these files and

### 10.0.0 (?)

* Support creating XML with AKN 3 namespace (http://docs.oasis-open.org/legaldocml/ns/akn/3.0)
* Add --namespace option to toggle between generate AKN2 and AKN3 documents
* Remove unnecessary schemaLocation header in root element
* BREAKING: default to AKN3 namespace
* BREAKING: Create XML with AKN 3 namespace (http://docs.oasis-open.org/legaldocml/ns/akn/3.0), AKN2 is no longer supported
* BREAKING: replace id attributes with eId attributes
* BREAKING: serialize schedules as attachments to act, not as components as peers of the act
* BREAKING: anonymous blocks are serialized as hcontainers, not paragraphs
* BREAKING: crossheading hcontainer IDs correctly use hcontainer
* Remove unnecessary schemaLocation header in root element

### 9.2.0 (10 June 2020)

Expand Down
4 changes: 1 addition & 3 deletions bin/slaw
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class SlawCLI < Thor
option :section_number_position, enum: ['before-title', 'after-title', 'guess'], desc: "Where do section titles come in relation to the section number? Default: before-title"
option :grammar, type: :string, desc: "Grammar name (usually a two-letter country code). Default is za."
option :ascii, type: :boolean, default: false, desc: "Process text as ASCII using %-encoding. This can provide significant speed improvements if the grammar uses only ASCII literals. See https://github.com/cjheath/treetop/issues/31."
option :namespace, enum: ['akn2', 'akn3'], default: 'akn3', desc: 'AKN XML namespace to use.'
option :namespace, enum: ['akn3'], default: 'akn3', desc: 'AKN XML namespace to use.'
def parse(name)
logging

Expand All @@ -35,8 +35,6 @@ class SlawCLI < Thor
end

case options[:namespace]
when 'akn2'
Slaw.akn_namespace = Slaw::AKN2_NS
when 'akn3'
Slaw.akn_namespace = Slaw::AKN3_NS
end
Expand Down
1 change: 0 additions & 1 deletion lib/slaw/namespace.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
module Slaw
AKN2_NS = 'http://www.akomantoso.org/2.0'
AKN3_NS = 'http://docs.oasis-open.org/legaldocml/ns/akn/3.0'

@@ns = AKN3_NS
Expand Down

0 comments on commit 79bc01c

Please sign in to comment.