From d79e8799e2953b4b07eedb494c7d5be7c6254acb Mon Sep 17 00:00:00 2001 From: philipp Date: Sun, 18 Feb 2024 16:51:32 +0100 Subject: [PATCH] add abgb --- laws/abgb.toml | 86 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 laws/abgb.toml diff --git a/laws/abgb.toml b/laws/abgb.toml new file mode 100644 index 0000000..88e680e --- /dev/null +++ b/laws/abgb.toml @@ -0,0 +1,86 @@ +[law] +id = 10001622 +name = "ABGB" + +[[law.classifiers]] +name = "Theil" +is_root = true +match_function = "containsCaseSensitive" + +[[law.classifiers]] +name = "Abtheilung" +is_root = false +match_function = "contains" + +[[law.classifiers]] +name = "Hauptstück" +is_root = false +match_function = "contains" + +[[law.classifiers]] +name = "Abschnitt" +is_root = false +match_function = "contains" + +[[law.classifiers]] +name = "letter" +is_root = false +match_function = "starts_with_letter" + +[[law.classifiers]] +name = "roman numbering" +is_root = false +match_function = "starts_with_roman_number" + +[[law.classifiers]] +name = "numbering" +is_root = false +match_function = "starts_with_number" + +[[law.classifiers]] +name = "dash" +is_root = false +match_function = "starts_with_dash" + +[parser] +remove_strings = [ + "", + "", "", + "", "", + "", "", + """Zweyter Theil.""", # weird thing after § 858 +] + +[[parser.replace_rules]] +find = "Einleitung." # Should be at the same level as the other "Theil"e +replace_with = "Nullter Theil. Einleitung" + +[[parser.replace_rules]] +find = "" +replace_with = "-" + +[[parser.replace_rules]] +find = """Medizinische Behandlung""" +replace_with = """- Medizinische Behandlung""" + +[[parser.replace_rules]] +find = """Von den dinglichen Rechten.""" +replace_with = """Von den dinglichen Rechten.""" + +[[parser.replace_rules]] +find = """Erfordernisse zur Ersitzung:""" +replace_with = """I. Erfordernisse zur Ersitzung:""" + +# RIS uses multiple headers to get more attention... +[[parser.replace_rules]] +find = """Zweyter Theildesbürgerlichen Gesetzbuches.Von dem Sachenrechte.""" +replace_with = """Zweyter Theil des bürgerlichen Gesetzbuches: Von dem Sachenrechte.""" + +[[parser.replace_rules]] +find = """Erste Abtheilungdes Sachenrechtes.""" +replace_with = """Erste Abtheilung des Sachenrechtes.""" + +[[parser.replace_rules]] +find = """Dritter Theildesbürgerlichen Gesetzbuches.Von den gemeinschaftlichen Bestimmungen der Personen- und Sachenrechte.""" +replace_with = """Dritter Theil des bürgerlichen Gesetzbuches.Von den gemeinschaftlichen Bestimmungen der Personen- und Sachenrechte.""" +