The document's optional content properties: every optional content group, the default and alternate configurations, and the visibility computation over them.
public sealed class PdfOptionalContentProperties
ISO 32000-2 §8.11 (PDF 1.5), §8.11.4.2, Table 98. Read from the catalog's OCProperties; when it is absent there is no
optional content and every optional content structure is ignored (OptionalContent is
null; all content is visible).
The group list (OCGs) and each group's intents are read when the view is created, recording the version of every container
read: OptionalContent returns a new view once OCProperties is replaced, any of them has changed,
or an object was added or removed (§7.3.10), and states computed from the old view are refused by the new one. Each
membership dictionary's compiled visibility is recompiled when its dictionary or arrays change or an object is added or removed. Everything else (configurations, names, usage) reads the COS objects on every
call. Nothing is ever written to the file: a missing D reads as an empty configuration with a diagnostic.
Visibility (§8.11.2, §8.11.3): content marked with a group listed in OCGs is visible when the group is ON; with a
membership dictionary, when its visibility expression or policy says so. Content marked with anything else (a group not listed,
a dictionary that is neither) is not optional content and is visible. Nested optional content is visible only when every
level is (PdfOptionalContentTracker). IsVisible(CosObject?, PdfOptionalContentState) allocates nothing once a membership is compiled.
kind:method, kind:property, kind:ctor. Press Esc to clear.ConfigurationsGets the alternate configurations (Configs).DefaultConfigurationGets the default configuration (D), which sets the initial states.DictionaryGets the optional content properties dictionary (OCProperties).GroupsGets every optional content group, in the order of OCGs (duplicates once).ApplyAutoStates(PdfOptionalContentState, PdfOptionalContentEvent, PdfOptionalContentUsageContext)Applies the auto-state (AS) entries of the state's configuration whose Event is usageEvent: each listed group's usage categories give a recommended state, and a group is ON only when all its recommendations are.ApplyUsageStates(PdfOptionalContentState, PdfOptionalContentEvent)Applies every group's usage state for usageEvent (ViewState, PrintState or ExportState) whether or not an auto-state entry asks for it, as pdf.js and PDFBox do. Not the specification's behaviour: for engine parity only.FindGroup(CosObject?)Returns the listed group value is (or refers to), or null.FindMembership(CosObject?)Returns a view over the membership dictionary value is (or refers to), or null.GetDefaultStates()Computes the initial states from the default configuration: BaseState, then ON, then OFF.GetStates(PdfOptionalContentConfiguration, PdfOptionalContentState?)Computes the states configuration gives when applied over current.IsVisible(CosObject?, PdfOptionalContentState)Returns whether content marked with ocgOrOcmd is visible under state.