|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.util.concurrent.locks.ReentrantReadWriteLock
com.guiseframework.prototype.AbstractPrototypeProvisionStrategy
com.guiseframework.prototype.AbstractCompositeComponentPrototypeProvisionStrategy
com.guiseframework.prototype.AbstractMenuToolCompositeComponentPrototypeProvisionStrategy
com.guiseframework.prototype.DefaultMenuToolPrototypeProvisionStrategy
public class DefaultMenuToolPrototypeProvisionStrategy
The default strategy for keeping track of prototype providers and working with provisioned prototypes, merging them into a menu and/or a toolbar.
When the prototype providers change provided prototypes, those provided prototypes are processed.
This version monitors the parent composite component children and automatically uses top-level prototype providers added to or removed from the hierarchy.
Prototype provisions are not processed initially; this strategy should be initialized after construction by calling AbstractPrototypeProvisionStrategy.processPrototypeProvisions().
This class is thread safe based upon its exposed read and write locks.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class java.util.concurrent.locks.ReentrantReadWriteLock |
|---|
java.util.concurrent.locks.ReentrantReadWriteLock.ReadLock, java.util.concurrent.locks.ReentrantReadWriteLock.WriteLock |
| Constructor Summary | |
|---|---|
DefaultMenuToolPrototypeProvisionStrategy(CompositeComponent parentComponent,
Menu menu,
Toolbar toolbar,
PrototypeProvider... defaultPrototypeProviders)
Parent component, menu, toolbar, and prototype providers constructor. |
|
| Method Summary | |
|---|---|
protected Menu |
getMenu()
|
protected Toolbar |
getToolbar()
|
| Methods inherited from class com.guiseframework.prototype.AbstractMenuToolCompositeComponentPrototypeProvisionStrategy |
|---|
add, getLastComponents, processPrototypeProvisions, synchronizePrototypeProvisionMap |
| Methods inherited from class com.guiseframework.prototype.AbstractCompositeComponentPrototypeProvisionStrategy |
|---|
getParentComponent |
| Methods inherited from class com.guiseframework.prototype.AbstractPrototypeProvisionStrategy |
|---|
addPrototypeProvider, gatherPrototypeProvisions, getPrototypeProviders, processPrototypeProvisions, removePrototypeProvider |
| Methods inherited from class java.util.concurrent.locks.ReentrantReadWriteLock |
|---|
getOwner, getQueuedReaderThreads, getQueuedThreads, getQueuedWriterThreads, getQueueLength, getReadHoldCount, getReadLockCount, getWaitingThreads, getWaitQueueLength, getWriteHoldCount, hasQueuedThread, hasQueuedThreads, hasWaiters, isFair, isWriteLocked, isWriteLockedByCurrentThread, readLock, toString, writeLock |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultMenuToolPrototypeProvisionStrategy(CompositeComponent parentComponent,
Menu menu,
Toolbar toolbar,
PrototypeProvider... defaultPrototypeProviders)
parentComponent - The composite component the top-level prototype provider children of which will be monitored.menu - The menu being managed, or null if no menu is being managed.toolbar - The toolbar being managed, or null if no toolbar is being managed.defaultPrototypeProviders - The default prototype providers that will provide prototypes for processing, outside the children of the composite component parent.
java.lang.NullPointerException - if the given parent component, prototype providers, and/or one or more prototype provider is null.| Method Detail |
|---|
protected Menu getMenu()
getMenu in class AbstractMenuToolCompositeComponentPrototypeProvisionStrategynull if no menu is being managed.protected Toolbar getToolbar()
getToolbar in class AbstractMenuToolCompositeComponentPrototypeProvisionStrategynull if no toolbar is being managed.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||