예제 #1
0
        public int CompareTo(object obj)
        {
            if (obj is NintendoU8File)
            {
                NintendoU8File o = (NintendoU8File)obj;

                return(this.FileName.CompareTo(o.FileName));
            }

            throw new ArgumentException("object is not a NintendoU8File");
        }
예제 #2
0
        private NintendoU8File getFileNode(FileStream fs, int nodeIndex, string parentDirectory)
        {
            // get node
            u8Node node = this.NodeList[nodeIndex];

            // get directory name
            string fileName = ParseFile.ReadAsciiString(fs, this.NameTableOffset + node.NameOffset);

            // create file item
            NintendoU8File newFile = new NintendoU8File(parentDirectory, this.SourceFileName,
                                                        fileName, node.DataOffset, this.VolumeBaseOffset, node.DataOffset, node.DataSize);

            return(newFile);
        }