static class WidgetPool.WidgetPoolHelper
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private WidgetPool.WorkArea |
wa
The
WidgetPool.WorkArea instance. |
| Constructor and Description |
|---|
WidgetPoolHelper(WidgetPool.WorkArea wa)
Create a new instance and associate the given WorkArea instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addResource(WrappedResource resource,
character name)
Adds the specified resource to the pool.
|
void |
deleteWidgetPools(java.lang.Object proc)
Delete all the non-persistent widget-pools associated with the specified procedure.
|
boolean |
hasUnnamedPool(java.lang.Object referent)
Checks if the given referent has an unnamed pool registered.
|
void |
removeResource(WrappedResource resource)
Remove the given resource from its pool, if it was pooled.
|
void |
scopeFinished(java.lang.Object oThis,
boolean external,
boolean persistent)
Delegates the call to
WidgetPool.WorkArea.scopeFinished(Object, boolean, boolean) |
void |
scopeStart(BlockDefinition block)
Delegates the call to
WidgetPool.WorkArea.scopeStart(com.goldencode.p2j.util.BlockDefinition) |
private final WidgetPool.WorkArea wa
WidgetPool.WorkArea instance.public WidgetPoolHelper(WidgetPool.WorkArea wa)
wa - The WidgetPool.WorkArea instance.public void addResource(WrappedResource resource, character name)
resource - The resource to be pooled.name - The pool name, set to null if the unnamed pool is to be used.java.lang.IllegalStateException - The exception is throw if the call of this method targets a named pool (the
name parameter is specified) and either the name is unknown or a pool
with the specified name does not exist.
If the exception is thrown, there must be an error in the code which creates the
resource. That code must validate the pool name (by calling
WidgetPool.validWidgetPool(com.goldencode.p2j.util.character)) before any other resource-related validation
and before the resource is created.
public boolean hasUnnamedPool(java.lang.Object referent)
referent - The referent to check.true if there is at least one unnamed pool for this referent.public void scopeStart(BlockDefinition block)
WidgetPool.WorkArea.scopeStart(com.goldencode.p2j.util.BlockDefinition)block - The explicit block definition which required this notification.public void scopeFinished(java.lang.Object oThis,
boolean external,
boolean persistent)
WidgetPool.WorkArea.scopeFinished(Object, boolean, boolean)public void removeResource(WrappedResource resource)
resource - The resource to be removed.public void deleteWidgetPools(java.lang.Object proc)
proc - The external procedure instance.