|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.jasperreports.engine.fill.JRVirtualizationContext
public class JRVirtualizationContext
Context used to store data shared by virtualized objects resulted from a report fill process.
| Constructor Summary | |
|---|---|
JRVirtualizationContext()
Constructs a context. |
|
| Method Summary | |
|---|---|
void |
cacheRenderer(JRPrintImage image)
Caches an image renderer. |
void |
cacheTemplate(JRTemplateElement template)
Caches an element template. |
JRRenderable |
getCachedRenderer(java.lang.String id)
Retrieves a cached image renderer based on an ID. |
JRTemplateElement |
getCachedTemplate(java.lang.String templateId)
Retrieves a cached template. |
static JRVirtualizationContext |
getRegistered(JasperPrint print)
Returns the virtualization context registered for a print object. |
boolean |
hasCachedRenderer(java.lang.String id)
Determines whether a cached image renderer for a specified ID exists. |
boolean |
hasCachedTemplate(java.lang.String id)
Determines whether a cached template with a specified ID exists. |
boolean |
isReadOnly()
Determines whether this context has been marked as read-only. |
static void |
register(JRVirtualizationContext context,
JasperPrint print)
Registers a virtualization context for JasperPrint object. |
void |
setReadOnly(boolean readOnly)
Sets the read-only flag for this context. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JRVirtualizationContext()
| Method Detail |
|---|
public void cacheRenderer(JRPrintImage image)
image - the image whose renderer should be cachedpublic JRRenderable getCachedRenderer(java.lang.String id)
id - the ID
public boolean hasCachedRenderer(java.lang.String id)
id - the ID
true if and only if the context contains a cached renderer with the specified IDpublic boolean hasCachedTemplate(java.lang.String id)
template with a specified ID exists.
id - the template ID
true if and only if the context contains a cached template with the specified IDpublic void cacheTemplate(JRTemplateElement template)
template - the template to cachepublic JRTemplateElement getCachedTemplate(java.lang.String templateId)
templateId - the template ID
public boolean isReadOnly()
setReadOnly(boolean)public void setReadOnly(boolean readOnly)
When in read-only mode, all the virtualizable objects belonging to this context are assumed final by the virtualizer and any change in a virtualizable object's data would be discarded on virtualization.
readOnly - the read-only flag
public static void register(JRVirtualizationContext context,
JasperPrint print)
JasperPrint object.
context - the virtualization contextprint - the print objectpublic static JRVirtualizationContext getRegistered(JasperPrint print)
When the engine fills a report using a virtualizer, it registers
the virtualization context with the generated JasperPrint object so that the caller
would be able to retrieve the context based on the returned print object.
print - a print object
null if no context
has been registered
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||