aboutsummaryrefslogtreecommitdiffstats
path: root/lib/asn1/test/asn1_SUITE_data/InfObjExtract.asn1
blob: 0ee8e178fd3f0c774d18a3e9f2c1ed581fbc0b40 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
InfObjExtract DEFINITIONS AUTOMATIC TAGS ::=
BEGIN

DATA-CLASS ::= CLASS {
  &id INTEGER UNIQUE,
  &Type
} WITH SYNTAX {
  ID &id
  TYPE &Type
}

data-object-1 DATA-CLASS ::= { ID 1 TYPE BOOLEAN }
data-object-2 DATA-CLASS ::= { ID 2 TYPE OCTET STRING }
data-object-3 DATA-CLASS ::= { ID 3 TYPE BIT STRING }

ObjSet DATA-CLASS ::= {
  holder-object-1.&obj |
  data-object-2 |
  data-object-3,
  ...
}

OBJ-SET DATA-CLASS ::= {
  holder-object-1.&obj |
  data-object-2 |
  data-object-3,
  ...
}

holder-object-1 HOLDER-CLASS ::= {
  OBJ data-object-1
}

holder-object-2 HOLDER-CLASS ::= {
  OBJ-SET {data-object-1}
}

holder-object-3 HOLDER-CLASS ::= {
  OBJ-SET {holder-object-2.&ObjSet}
}

-- Note: References to object sets with names in all uppercase/hyphens
-- may be represented differently compared to object sets with names
-- that contain lowercase letters. CAVEAT TESTOR.

HOLDER-OBJECTS HOLDER-CLASS ::= { holder-object-2 }
HolderObjects HOLDER-CLASS ::= { holder-object-3 }

holder-object-4 HOLDER-CLASS ::= {
  OBJ-SET { HOLDER-OBJECTS.&ObjSet }
}

holder-object-5 HOLDER-CLASS ::= {
  OBJ-SET { HolderObjects.&ObjSet }
}

holder-object-6 HOLDER-CLASS ::= {
  OBJ-SET { OBJ-SET }
}

holder-object-7 HOLDER-CLASS ::= {
  OBJ-SET { ObjSet  }
}

HOLDER-CLASS ::= CLASS {
  &obj DATA-CLASS OPTIONAL,
  &ObjSet DATA-CLASS OPTIONAL
} WITH SYNTAX {
  [OBJ &obj]
  [OBJ-SET &ObjSet]
}

TestSeq{DATA-CLASS:ObjectSet} ::= SEQUENCE {
  id DATA-CLASS.&id ({ObjectSet}),
  data DATA-CLASS.&Type ({ObjectSet}{@id})
}

DataSeq-1 ::= TestSeq{ {ObjSet} }
DataSeq-2 ::= TestSeq{ {holder-object-3.&ObjSet} }

DataSeq-3 ::= TestSeq{ {holder-object-4.&ObjSet} }
DataSeq-4 ::= TestSeq{ {holder-object-5.&ObjSet} }
DataSeq-5 ::= TestSeq{ {holder-object-6.&ObjSet} }
DataSeq-6 ::= TestSeq{ {holder-object-7.&ObjSet} }

END