Example #1
0
        // Token: 0x060001DB RID: 475 RVA: 0x00006CF8 File Offset: 0x00004EF8
        public static object readPlist(Stream stream, plistType type)
        {
            if (type == plistType.Auto)
            {
                type = Plist.getPlistType(stream);
                stream.Seek(0L, SeekOrigin.Begin);
            }
            if (type == plistType.Binary)
            {
                using (BinaryReader binaryReader = new BinaryReader(stream))
                {
                    byte[] data = binaryReader.ReadBytes(checked ((int)binaryReader.BaseStream.Length));
                    return(Plist.readBinary(data));
                }
            }
            XmlDocument xmlDocument = new XmlDocument();

            xmlDocument.XmlResolver = null;
            xmlDocument.Load(stream);
            return(Plist.readXml(xmlDocument));
        }