Package org.apache.fop.render.ps
Class FontResourceCache
- java.lang.Object
-
- org.apache.fop.render.ps.FontResourceCache
-
class FontResourceCache extends java.lang.Object
A cache for font resource objects.
-
-
Field Summary
Fields Modifier and Type Field Description private FontInfo
fontInfo
private java.util.Map
fontResources
This is a map of PSResource instances of all fonts defined (key: font key)
-
Constructor Summary
Constructors Constructor Description FontResourceCache(FontInfo fontInfo)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAll(java.util.Map fontMap)
Adds a number of fonts to the cache.PSFontResource
getFontResourceForFontKey(java.lang.String key)
Returns the PSFontResource for the given font key.private java.lang.String
getPostScriptNameForFontKey(java.lang.String key)
-
-
-
Field Detail
-
fontInfo
private final FontInfo fontInfo
-
fontResources
private java.util.Map fontResources
This is a map of PSResource instances of all fonts defined (key: font key)
-
-
Constructor Detail
-
FontResourceCache
public FontResourceCache(FontInfo fontInfo)
-
-
Method Detail
-
getFontResourceForFontKey
public PSFontResource getFontResourceForFontKey(java.lang.String key)
Returns the PSFontResource for the given font key.- Parameters:
key
- the font key ("F*")- Returns:
- the matching PSFontResource instance
-
getPostScriptNameForFontKey
private java.lang.String getPostScriptNameForFontKey(java.lang.String key)
-
addAll
public void addAll(java.util.Map fontMap)
Adds a number of fonts to the cache.- Parameters:
fontMap
- the font map
-
-