Example #1
0
    def __getattr__(self, name):
        result = Syntax.__getattr__(self, name)
        if result is not None:
            return result

        # Section からサブシンタックスを全て走査しても見つからなかった場合は
        # AttributeError を投げる
        raise AttributeError("'{}' object has no attribute '{}'".format(
            self.__class__.__name__, name))
Example #2
0
    def __getattr__(self, name):
        result = Syntax.__getattr__(self, name)
        if result is not None:
            return result

        # Section からサブシンタックスを全て走査しても見つからなかった場合は
        # AttributeError を投げる
        raise AttributeError("'{}' object has no attribute '{}'".format(
            self.__class__.__name__, name))
Example #3
0
 def __init__(self, packet, pos=0, parent=None):
     Syntax.__init__(self, packet, pos, parent)
     self.callbacks = dict()
Example #4
0
 def __init__(self, packet, pos=0, parent=None):
     Syntax.__init__(self, packet, pos, parent)
     self.callbacks = dict()