Class PDOptionalContentGroup

java.lang.Object
org.apache.pdfbox.pdmodel.graphics.optionalcontent.PDOptionalContentGroup
All Implemented Interfaces:
COSObjectable

public class PDOptionalContentGroup extends Object implements COSObjectable
This class represents an optional content group (OCG).
Since:
PDF 1.5
Version:
$Revision$
  • Constructor Details

    • PDOptionalContentGroup

      public PDOptionalContentGroup(String name)
      Creates a new optional content group (OCG).
      Parameters:
      name - the name of the content group
    • PDOptionalContentGroup

      public PDOptionalContentGroup(COSDictionary dict)
      Creates a new instance based on a given COSDictionary.
      Parameters:
      dict - the dictionary
  • Method Details

    • getCOSObject

      public COSBase getCOSObject()
      Convert this standard java object to a COS object.
      Specified by:
      getCOSObject in interface COSObjectable
      Returns:
      The cos object that matches this Java object.
    • getName

      public String getName()
      Returns the name of the optional content group.
      Returns:
      the name
    • setName

      public void setName(String name)
      Sets the name of the optional content group.
      Parameters:
      name - the name
    • toString

      public String toString()
      Overrides:
      toString in class Object