]> Cypherpunks.ru repositories - pyderasn.git/blobdiff - pyderasn.pyi
Note about value removing from Sequence
[pyderasn.git] / pyderasn.pyi
index 83f00329d7d65dcb2bcd404a3ba04869d5931918..1c784fbb2fe15f0018132bb5864048c55b048d90 100644 (file)
@@ -118,6 +118,7 @@ class Obj:
             offset: int=...,
             leavemm: bool=...,
             decode_path: Tuple[str, ...]=...,
+            ctx: Optional[Dict[str, TAny]]=...,
     ) -> Tuple[Obj, bytes]: ...
 
     @property
@@ -183,6 +184,7 @@ class Boolean(Obj):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "Boolean"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -215,6 +217,7 @@ class Integer(Obj):
     asn1_type_name = ...  # type: str
     specs = ...  # type: Dict[str, int]
     default = ...  # type: "Integer"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -254,6 +257,7 @@ class BitString(Obj):
     asn1_type_name = ...  # type: str
     specs = ...  # type: Dict[str, int]
     default = ...  # type: "BitString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -293,6 +297,8 @@ class OctetString(Obj):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "OctetString"
+    optional = ...  # type: bool
+    defined = ...  # type: Tuple[ObjectIdentifier, Obj]
 
     def __init__(
             self,
@@ -328,6 +334,7 @@ class Null(Obj):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "Null"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -355,10 +362,12 @@ class ObjectIdentifier(Obj):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "ObjectIdentifier"
+    optional = ...  # type: bool
 
     def __init__(
             self,
             value: Optional[Union["ObjectIdentifier", str, Tuple[int, ...]]]=...,
+            defines: Optional[Sequence[Tuple[str, Dict["ObjectIdentifier", Obj]]]],
             impl: Optional[bytes]=...,
             expl: Optional[bytes]=...,
             default: Optional[Union["ObjectIdentifier", str, Tuple[int, ...]]]=...,
@@ -391,6 +400,7 @@ class Enumerated(Integer):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "Enumerated"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -426,6 +436,7 @@ class UTF8String(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "UTF8String"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -445,6 +456,7 @@ class NumericString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "NumericString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -462,6 +474,7 @@ class PrintableString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "PrintableString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -479,6 +492,7 @@ class TeletexString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "TeletexString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -494,6 +508,7 @@ class TeletexString(CommonString):
 class T61String(TeletexString):
     asn1_type_name = ...  # type: str
     default = ...  # type: "T61String"
+    optional = ...  # type: bool
 
 
 class VideotexString(CommonString):
@@ -501,6 +516,7 @@ class VideotexString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "VideotexString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -518,6 +534,7 @@ class IA5String(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "IA5String"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -535,6 +552,7 @@ class UTCTime(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "UTCTime"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -554,6 +572,7 @@ class GeneralizedTime(UTCTime):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "GeneralizedTime"
+    optional = ...  # type: bool
 
     def todatetime(self) -> datetime: ...
 
@@ -563,6 +582,7 @@ class GraphicString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "GraphicString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -580,6 +600,7 @@ class VisibleString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "VisibleString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -595,6 +616,7 @@ class VisibleString(CommonString):
 class ISO646String(VisibleString):
     asn1_type_name = ...  # type: str
     default = ...  # type: "ISO646String"
+    optional = ...  # type: bool
 
 
 class GeneralString(CommonString):
@@ -602,6 +624,7 @@ class GeneralString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "GeneralString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -619,6 +642,7 @@ class UniversalString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "UniversalString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -636,6 +660,7 @@ class BMPString(CommonString):
     encoding = ...  # type: str
     asn1_type_name = ...  # type: str
     default = ...  # type: "BMPString"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -653,6 +678,7 @@ class Choice(Obj):
     asn1_type_name = ...  # type: str
     specs = ...  # type: Dict[str, Obj]
     default = ...  # type: "Choice"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -703,6 +729,8 @@ class Any(Obj):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "Any"
+    optional = ...  # type: bool
+    defined = ...  # type: Tuple[ObjectIdentifier, Obj]
 
     def __init__(
             self,
@@ -736,6 +764,7 @@ class Sequence(Obj):
     asn1_type_name = ...  # type: str
     specs = ...  # type: Dict[str, Obj]
     default = ...  # type: "Sequence"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -771,6 +800,7 @@ class Set(Sequence):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "Set"
+    optional = ...  # type: bool
 
 
 class SequenceOf(Obj):
@@ -778,6 +808,7 @@ class SequenceOf(Obj):
     asn1_type_name = ...  # type: str
     spec = ...  # type: Obj
     default = ...  # type: "SequenceOf"
+    optional = ...  # type: bool
 
     def __init__(
             self,
@@ -817,6 +848,7 @@ class SetOf(SequenceOf):
     tag_default = ...  # type: bytes
     asn1_type_name = ...  # type: str
     default = ...  # type: "SetOf"
+    optional = ...  # type: bool
 
 
 def obj_by_path(pypath: str) -> TAny: ...