code: public PdfTemplate getTopLayer() {
          if (frm == null) {
              frm = new PdfTemplate(writer);
              frm.setBoundingBox(rect);
              writer.addDirectTemplateSimple(frm, new PdfName("FRM"));
          }
          return frm;
      }
docs: Gets the template that aggregates all appearance layers. This corresponds to the /FRM resource.
  <p>
  Consult <A HREF="http://partners.adobe.com/asn/developer/pdfs/tn/PPKAppearances.pdf">PPKAppearances.pdf</A>
  for further details.
  @return the template that aggregates all appearance layers