Ejemplo n.º 1
0
        public PdfCatalog(PdfDictionary catalog)
            : base(PdfObjectType.Catalog)
        {
            IsContainer = true;
            catalog.ExpectsType("Catalog");

            foreach (PdfKeyValuePair pair in catalog.Items)
            {
                switch (pair.Key.Text)
                {
                case "Type":     // skip Type Catalog
                    break;

                case "Pages":
                    Pages = new PdfPageTree(catalog["Pages"] as PdfIndirectReference);
                    break;

                default:
                    _items.Add(pair);
                    break;
                }
            }
        }