Class FontResourceCache

java.lang.Object
org.apache.fop.render.ps.FontResourceCache

class FontResourceCache extends Object
A cache for font resource objects.
  • Field Details

    • fontInfo

      private final FontInfo fontInfo
    • fontResources

      private Map fontResources
      This is a map of PSResource instances of all fonts defined (key: font key)
  • Constructor Details

    • FontResourceCache

      public FontResourceCache(FontInfo fontInfo)
  • Method Details

    • getFontResourceForFontKey

      public PSFontResource getFontResourceForFontKey(String key)
      Returns the PSFontResource for the given font key.
      Parameters:
      key - the font key ("F*")
      Returns:
      the matching PSFontResource instance
    • getPostScriptNameForFontKey

      private String getPostScriptNameForFontKey(String key)
    • addAll

      public void addAll(Map fontMap)
      Adds a number of fonts to the cache.
      Parameters:
      fontMap - the font map