Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
Asn1DecoderBer.cs
1using System;
2using System.Collections.Generic;
3using System.IO;
4
5namespace Waher.Content.Asn1
6{
11 {
12 private readonly Stream input;
13
18 public Asn1DecoderBer(Stream Input)
19 {
20 this.input = Input;
21 }
22
29 public long DecodeIdentifier(out bool Constructed, out TagClass Class)
30 {
31 return BER.DecodeIdentifier(this.input, out Constructed, out Class);
32 }
33
39 public long DecodeLength(Stream Input)
40 {
41 return BER.DecodeLength(this.input);
42 }
43
49 public bool DecodeBOOLEAN(Stream Input)
50 {
51 return BER.DecodeBOOLEAN(this.input);
52 }
53
59 public long DecodeINTEGER(Stream Input)
60 {
61 return BER.DecodeINTEGER(this.input);
62 }
63
70 public Enum DecodeEnum<T>(Stream Input)
71 where T : Enum
72 {
73 return BER.DecodeEnum<T>(this.input);
74 }
75
81 public double DecodeREAL(Stream Input)
82 {
83 return BER.DecodeREAL(this.input);
84 }
85
92 public byte[] DecodeBitString(Stream Input, out int NrUnusedBits)
93 {
94 return BER.DecodeBitString(this.input, out NrUnusedBits);
95 }
96
102 public byte[] DecodeOctetString(Stream Input)
103 {
104 return BER.DecodeOctetString(this.input);
105 }
106
112 public void DecodeNull(Stream Input)
113 {
114 BER.DecodeNull(this.input);
115 }
116
122 public int[] DecodeObjectId(Stream Input)
123 {
124 return BER.DecodeObjectId(this.input);
125 }
126
127
133 public int[] DecodeRelativeObjectId(Stream Input)
134 {
135 return BER.DecodeRelativeObjectId(this.input);
136 }
137
143 public string DecodeBmpString(Stream Input)
144 {
145 return BER.DecodeBmpString(this.input);
146 }
147
153 public string DecodeIa5String(Stream Input)
154 {
155 return BER.DecodeIa5String(this.input);
156 }
157
163 public string DecodeVisibleString(Stream Input)
164 {
165 return BER.DecodeVisibleString(this.input);
166 }
167
173 public string DecodeUtf8String(Stream Input)
174 {
175 return BER.DecodeUtf8String(this.input);
176 }
177
183 public string DecodeUniversalString(Stream Input)
184 {
185 return BER.DecodeUniversalString(this.input);
186 }
187
193 public string DecodePrintableString(Stream Input)
194 {
195 return BER.DecodePrintableString(this.input);
196 }
197
203 public string DecodeNumericString(Stream Input)
204 {
205 return BER.DecodeNumericString(this.input);
206 }
207
213 public TimeSpan DecodeTime(Stream Input)
214 {
215 return BER.DecodeTime(this.input);
216 }
217
223 public DateTime DecodeDate(Stream Input)
224 {
225 return BER.DecodeDate(this.input);
226 }
227
233 public TimeSpan DecodeTimeOfDay(Stream Input)
234 {
235 return BER.DecodeTimeOfDay(this.input);
236 }
237
243 public DateTime DecodeDateTime(Stream Input)
244 {
245 return BER.DecodeDateTime(this.input);
246 }
247
253 public Duration DecodeDuration(Stream Input)
254 {
255 return BER.DecodeDuration(this.input);
256 }
257
258 }
259}
Basic Encoding Rules (BER), as defined in X.690
string DecodeUniversalString(Stream Input)
Decodes a UniversalString value.
Enum DecodeEnum< T >(Stream Input)
Decodes an enumerated value.
long DecodeLength(Stream Input)
Decodes the length of a contents section.
byte[] DecodeBitString(Stream Input, out int NrUnusedBits)
Decodes a BIT STRING value.
string DecodeBmpString(Stream Input)
Decodes a BmpString value.
DateTime DecodeDateTime(Stream Input)
Decodes a DATE-TIME value.
string DecodeUtf8String(Stream Input)
Decodes a Utf8String value.
TimeSpan DecodeTime(Stream Input)
Decodes a TIME value.
int[] DecodeRelativeObjectId(Stream Input)
Decodes a RELATIVE-OID value.
Asn1DecoderBer(Stream Input)
Basic Encoding Rules (BER), as defined in X.690
bool DecodeBOOLEAN(Stream Input)
Decodes a BOOLEAN value.
DateTime DecodeDate(Stream Input)
Decodes a DATE value.
double DecodeREAL(Stream Input)
Decodes a REAL value.
string DecodeVisibleString(Stream Input)
Decodes a VisibleString value.
long DecodeIdentifier(out bool Constructed, out TagClass Class)
Decodes an identifier from the stream.
void DecodeNull(Stream Input)
Decodes a NULL value.
int[] DecodeObjectId(Stream Input)
Decodes an OBJECT IDENTIFIER value.
TimeSpan DecodeTimeOfDay(Stream Input)
Decodes a TIME-OF-DAY value.
string DecodeIa5String(Stream Input)
Decodes a IA5String value.
byte[] DecodeOctetString(Stream Input)
Decodes a OCTET STRING value.
Duration DecodeDuration(Stream Input)
Decodes a DURATION value.
string DecodePrintableString(Stream Input)
Decodes a PrintableString value.
long DecodeINTEGER(Stream Input)
Decodes an INTEGER value.
string DecodeNumericString(Stream Input)
Decodes a NumericString value.
Implements static methods for Basic Encoding Rules (BER), as defined in X.690
Definition: BER.cs:14
static long DecodeIdentifier(Stream Input, out bool Constructed, out TagClass Class)
Decodes an identifier from the stream.
Definition: BER.cs:22
static TimeSpan DecodeTime(Stream Input)
Decodes a TIME value.
Definition: BER.cs:499
static TimeSpan DecodeTimeOfDay(Stream Input)
Decodes a TIME-OF-DAY value.
Definition: BER.cs:522
static void DecodeNull(Stream Input)
Decodes a NULL value.
Definition: BER.cs:370
static string DecodeIa5String(Stream Input)
Decodes a IA5String value.
Definition: BER.cs:439
static string DecodeVisibleString(Stream Input)
Decodes a VisibleString value.
Definition: BER.cs:449
static DateTime DecodeDateTime(Stream Input)
Decodes a DATE-TIME value.
Definition: BER.cs:532
static long DecodeINTEGER(Stream Input)
Decodes an INTEGER value.
Definition: BER.cs:131
static string DecodePrintableString(Stream Input)
Decodes a PrintableString value.
Definition: BER.cs:479
static long DecodeLength(Stream Input)
Decodes the length of a contents section.
Definition: BER.cs:63
static DateTime DecodeDate(Stream Input)
Decodes a DATE value.
Definition: BER.cs:509
static string DecodeBmpString(Stream Input)
Decodes a BmpString value.
Definition: BER.cs:429
static Duration DecodeDuration(Stream Input)
Decodes a DURATION value.
Definition: BER.cs:545
static byte[] DecodeBitString(Stream Input, out int NrUnusedBits)
Decodes a BIT STRING value.
Definition: BER.cs:279
static int[] DecodeRelativeObjectId(Stream Input)
Decodes a RELATIVE-OID value.
Definition: BER.cs:419
static double DecodeREAL(Stream Input)
Decodes a REAL value.
Definition: BER.cs:164
static string DecodeNumericString(Stream Input)
Decodes a NumericString value.
Definition: BER.cs:489
static bool DecodeBOOLEAN(Stream Input)
Decodes a BOOLEAN value.
Definition: BER.cs:114
static string DecodeUniversalString(Stream Input)
Decodes a UniversalString value.
Definition: BER.cs:469
static byte[] DecodeOctetString(Stream Input)
Decodes a OCTET STRING value.
Definition: BER.cs:327
static string DecodeUtf8String(Stream Input)
Decodes a Utf8String value.
Definition: BER.cs:459
static int[] DecodeObjectId(Stream Input)
Decodes an OBJECT IDENTIFIER value.
Definition: BER.cs:381
Interface for ASN.1 decoders
Definition: IAsn1Decoder.cs:11
TagClass
TAG class
Definition: TagClass.cs:11
Represents a duration value, as defined by the xsd:duration data type: http://www....
Definition: Duration.cs:13