code: def parse(self, buffer, inlineparent = None):
          '''
          Compatible to Parser.parse()
          '''
          if len(buffer) < self.struct.size:
              return None
          try:
              return (self.struct.unpack(buffer[:self.struct.size])[0], self.struct.size)
          except struct.error as exc:
              raise BadFormatError(excf parse(self, buffer, inlineparent = None):
          '''
          Compatible to Parser.parse()
          '''
          if len(buffer) < self.struct.size:
              return None
          try:
              return (self.struct.unpack(buffer[:self.struct.size])[0], self.struct.size)
          except struct.error as exc:
              raise BadFormatError(exc)
docs: Compatible to Parser.parse()