iText 7 7.1.9 API
iText.Kernel.Pdf.Action.PdfActionOcgState Class Reference

This is a helper class for optional content states use in Set-OCG-State actions. More...

Public Member Functions

  PdfActionOcgState (PdfName state, IList< PdfDictionary > ocgs)
  Constructs an optional content state object. More...
 
virtual PdfName  GetState ()
  Gets the state the optional content groups should be switched to More...
 
virtual IList< PdfDictionary GetOcgs ()
  Gets a list of optional content groups that shall have the state changed More...
 
virtual IList< PdfObject GetObjectList ()
  Gets a list of iText.Kernel.Pdf.PdfObject that is describing this particular optional content group states. More...
 

Detailed Description

This is a helper class for optional content states use in Set-OCG-State actions.

This is a helper class for optional content states use in Set-OCG-State actions. See PdfAction.CreateSetOcgState(System.Collections.Generic.IList<E>).

Constructor & Destructor Documentation

◆ PdfActionOcgState()

iText.Kernel.Pdf.Action.PdfActionOcgState.PdfActionOcgState ( PdfName  state,
IList< PdfDictionary ocgs 
)
inline

Constructs an optional content state object.

Parameters
state a iText.Kernel.Pdf.PdfName describing the state. Shall be one of the following: iText.Kernel.Pdf.PdfName.OFF , iText.Kernel.Pdf.PdfName.ON , iText.Kernel.Pdf.PdfName.Toggle
ocgs a list of the OCG dictionaries

Member Function Documentation

◆ GetObjectList()

virtual IList<PdfObject> iText.Kernel.Pdf.Action.PdfActionOcgState.GetObjectList ( )
inlinevirtual

Gets a list of iText.Kernel.Pdf.PdfObject that is describing this particular optional content group states.

Returns
a list of iText.Kernel.Pdf.PdfObject for construction of a iText.Kernel.Pdf.PdfArray

◆ GetOcgs()

virtual IList<PdfDictionary> iText.Kernel.Pdf.Action.PdfActionOcgState.GetOcgs ( )
inlinevirtual

Gets a list of optional content groups that shall have the state changed

Returns
the list of optional content groups

◆ GetState()

virtual PdfName iText.Kernel.Pdf.Action.PdfActionOcgState.GetState ( )
inlinevirtual

Gets the state the optional content groups should be switched to

Returns
the state, one of the following: iText.Kernel.Pdf.PdfName.OFF , iText.Kernel.Pdf.PdfName.ON , iText.Kernel.Pdf.PdfName.Toggle