author | František Kučera <franta-hg@frantovo.cz> |
Thu, 22 Jul 2021 20:01:03 +0200 | |
branch | v_0 |
changeset 40 | 85b6f13f1088 |
child 41 | 12acb6c02d32 |
permissions | -rw-r--r-- |
40
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
1 |
/** |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
2 |
* Relational pipes |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
3 |
* Copyright © 2021 František Kučera (Frantovo.cz, GlobalCode.info; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
4 |
* |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
5 |
* This program is free software: you can redistribute it and/or modify |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
6 |
* it under the terms of the GNU General Public License as published by |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
7 |
* the Free Software Foundation, version 3 of the License. |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
8 |
* |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
9 |
* This program is distributed in the hope that it will be useful, |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
12 |
* GNU General Public License for more details. |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
13 |
* |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
14 |
* You should have received a copy of the GNU General Public License |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
15 |
* along with this program. If not, see <http://www.gnu.org/licenses/>. |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
16 |
*/ |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
17 |
#pragma once |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
18 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
19 |
namespace relpipe { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
20 |
namespace in { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
21 |
namespace asn1 { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
22 |
namespace lib { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
23 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
24 |
// TODO: these strings will become globally unique URIs (or IRIs) after moving to alt2xml and relative/unprefixed names should also work |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
25 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
26 |
/** general options of the ASN.1 parser */ |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
27 |
namespace option { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
28 |
static const char* Encoding = "encoding"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
29 |
static const char* ParseEncapsulated = "parse-encapsulated"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
30 |
} |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
31 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
32 |
namespace encoding { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
33 |
static const char* ber = "BER"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
34 |
static const char* der = "DER"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
35 |
static const char* cer = "CER"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
36 |
static const char* xer = "XER"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
37 |
static const char* per = "PER"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
38 |
static const char* asn1 = "ASN.1"; // schema, model |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
39 |
} |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
40 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
41 |
/** options for configuring the stage where events from the ASN.1 parser are converted to SAX events or DOM building */ |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
42 |
namespace xml { |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
43 |
static const char* TreeWithNamespaces = "tree-with-namespaces"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
44 |
static const char* TreeStyle = "tree-style"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
45 |
static const char* RootName = "root-name"; |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
46 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
47 |
static const char* XMLNS = "tag:globalcode.info,2018:alt2xml:TEMPORARY:asn1"; // not an option and might change, just preliminary namespace |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
48 |
} |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
49 |
|
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
50 |
} |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
51 |
} |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
52 |
} |
85b6f13f1088
configuration: --parser-option encoding, parse-encapsulated, root-name, tree-style, tree-with-namespaces
František Kučera <franta-hg@frantovo.cz>
parents:
diff
changeset
|
53 |
} |