예제 #1
0
    def parseData(self):
        data_stream = StreamParser(self.data)
        count = data_stream.readInt(4)
        data_stream.burn(4)

        for i in range(count):
            new_child = self.Child(data_stream)
            self.children.update({new_child.string: new_child})
예제 #2
0
    def __init__(self, data):
        self.data = data
        stream = StreamParser(data)

        self.dependecies = []

        # for now, this will do for gathering the dependencies
        stream.burn(8)
        header_size = stream.readInt(4)
        stream.burn(4)
        self.name = stream.readString()
        stream.seek(header_size)
        stream.burn(15)
        dependency_count = stream.readInt(4)
        stream.burn(6)
        for i in range(dependency_count):
            self.dependecies.append(stream.readString())
            stream.burn(6)