Esempio n. 1
0
 def __init__(self, subcon, width, swapped = False, signed = False,
              bytesize = 8):
     Adapter.__init__(self, subcon)
     self.width = width
     self.swapped = swapped
     self.signed = signed
     self.bytesize = bytesize
Esempio n. 2
0
 def __init__(self, subcon, decoding, encoding,
              decdefault = NotImplemented, encdefault = NotImplemented):
     Adapter.__init__(self, subcon)
     self.decoding = decoding
     self.encoding = encoding
     self.decdefault = decdefault
     self.encdefault = encdefault
Esempio n. 3
0
 def __init__(self, subcon, padchar = six.b("\x00"), paddir = "right", trimdir = "right"):
     if paddir not in ("right", "left", "center"):
         raise ValueError("paddir must be 'right', 'left' or 'center'", paddir)
     if trimdir not in ("right", "left"):
         raise ValueError("trimdir must be 'right' or 'left'", trimdir)
     Adapter.__init__(self, subcon)
     self.padchar = padchar
     self.paddir = paddir
     self.trimdir = trimdir
Esempio n. 4
0
 def __init__(self,
              subcon,
              decoding,
              encoding,
              decdefault=NotImplemented,
              encdefault=NotImplemented):
     Adapter.__init__(self, subcon)
     self.decoding = decoding
     self.encoding = encoding
     self.decdefault = decdefault
     self.encdefault = encdefault
Esempio n. 5
0
 def __init__(self,
              subcon,
              padchar=six.b("\x00"),
              paddir="right",
              trimdir="right"):
     if paddir not in ("right", "left", "center"):
         raise ValueError("paddir must be 'right', 'left' or 'center'",
                          paddir)
     if trimdir not in ("right", "left"):
         raise ValueError("trimdir must be 'right' or 'left'", trimdir)
     Adapter.__init__(self, subcon)
     self.padchar = padchar
     self.paddir = paddir
     self.trimdir = trimdir
Esempio n. 6
0
 def __init__(self, subcon, value):
     Adapter.__init__(self, subcon)
     self.value = value
Esempio n. 7
0
 def __init__(self, subcon, linesize = 16):
     Adapter.__init__(self, subcon)
     self.linesize = linesize
Esempio n. 8
0
 def __init__(self, subcon, encoder, decoder):
     Adapter.__init__(self, subcon)
     self._encode = encoder
     self._decode = decoder
Esempio n. 9
0
 def __init__(self, subcon, inner_subcon):
     Adapter.__init__(self, subcon)
     self.inner_subcon = inner_subcon
Esempio n. 10
0
 def __init__(self, subcon, linesize=16):
     Adapter.__init__(self, subcon)
     self.linesize = linesize
Esempio n. 11
0
 def __init__(self, subcon, inner_subcon):
     Adapter.__init__(self, subcon)
     self.inner_subcon = inner_subcon
Esempio n. 12
0
 def __init__(self, subcon, pattern = six.b("\x00"), strict = False):
     Adapter.__init__(self, subcon)
     self.pattern = pattern
     self.strict = strict
Esempio n. 13
0
 def __init__(self, subcon, pattern=six.b("\x00"), strict=False):
     Adapter.__init__(self, subcon)
     self.pattern = pattern
     self.strict = strict
Esempio n. 14
0
 def __init__(self, subcon, width, swapped=False, signed=False, bytesize=8):
     Adapter.__init__(self, subcon)
     self.width = width
     self.swapped = swapped
     self.signed = signed
     self.bytesize = bytesize
Esempio n. 15
0
 def __init__(self, subcon, index):
     Adapter.__init__(self, subcon)
     if type(index) is not int:
         raise TypeError("index must be an integer", type(index))
     self.index = index
Esempio n. 16
0
 def __init__(self, subcon, start, stop=None):
     Adapter.__init__(self, subcon)
     self.start = start
     self.stop = stop
Esempio n. 17
0
 def __init__(self, subcon, value):
     Adapter.__init__(self, subcon)
     self.value = value
Esempio n. 18
0
 def __init__(self, subcon, start, stop = None):
     Adapter.__init__(self, subcon)
     self.start = start
     self.stop = stop
Esempio n. 19
0
 def __init__(self, subcon, encoding=None):
     Adapter.__init__(self, subcon)
     self.encoding = encoding
Esempio n. 20
0
 def __init__(self, subcon, index):
     Adapter.__init__(self, subcon)
     if type(index) is not int:
         raise TypeError("index must be an integer", type(index))
     self.index = index
Esempio n. 21
0
 def __init__(self, subcon, encoding = None):
     Adapter.__init__(self, subcon)
     self.encoding = encoding
Esempio n. 22
0
 def __init__(self, subcon, fmt, **fmt_kwargs):
     Adapter.__init__(self, subcon)
     self.fmt = fmt
     self.fmt_kwargs = fmt_kwargs
Esempio n. 23
0
 def __init__(self, subcon, encoder, decoder):
     Adapter.__init__(self, subcon)
     self._encode = encoder
     self._decode = decoder
Esempio n. 24
0
 def __init__(self, subcon, flags):
     Adapter.__init__(self, subcon)
     self.flags = flags
Esempio n. 25
0
 def __init__(self, subcon, flags):
     Adapter.__init__(self, subcon)
     self.flags = flags