|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfacets.util.Tracer
facets.core.app.AppSurface
facets.core.app.ActionAppSurface
facets.facet.app.FacetAppSurface
public abstract class FacetAppSurface
ActionAppSurface with a built-in FacetFactory.
FacetAppSurface extends its superclass primarily by
passing the FacetAppSpecifier which is set as AppSurface.spec;
this in turn supplies a FacetFactory which can either be used as-is or
provide a core for content-specific subclasses.
Further general-purpose functionality
is suppled by FacetAppSpecifier and FacetAppActions members of
FacetAppSpecifier.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class facets.core.app.ActionAppSurface |
|---|
ActionAppSurface.CachingStyle |
| Nested classes/interfaces inherited from class facets.core.app.AppSurface |
|---|
AppSurface.ContentCreationException, AppSurface.Contenter, AppSurface.ContentRoot, AppSurface.ContentStyle |
| Field Summary | |
|---|---|
FacetFactory |
ff
For use by subclasses and AppSurface.Contenters |
| Fields inherited from class facets.core.app.ActionAppSurface |
|---|
actions, KEY_TIMED_OUT, KEY_TIMEOUTS, memory, watcher |
| Fields inherited from class facets.core.app.AppSurface |
|---|
AREA_APP, AREA_CONTENT, AREA_PAGE, AREA_PANE, contentStyle, emptyContent, spec, TITLE_EMPTY |
| Constructor Summary | |
|---|---|
FacetAppSurface(FacetAppSpecifier spec,
FacetFactory ff)
Unique constructor. |
|
| Method Summary | |
|---|---|
protected void |
appClosing()
Called before a true return from closeAcceptable(WindowAppHost). |
protected void |
appOpened()
Called from openApp(). |
java.lang.String |
areaTitle(int depth)
|
protected ActionAppSurface.CachingStyle |
cachingStyle()
|
protected long |
calculateCacheMb(int maxSafeMb)
|
boolean |
closeAcceptable(WindowAppHost host)
Check to see if a non-applet app can be closed. |
void |
debugWatch(java.lang.String callName,
boolean providing,
boolean exception)
|
Dialogs |
dialogs()
The Dialogs created during openApp(). |
MenuFacets |
getContextMenuFacets()
Implements interface method. |
FileSpecifier[] |
getFileSpecifiers()
What files can the application open? |
protected java.lang.Object |
getInternalContentSource()
Implements abstract method. |
void |
handleInvalidInput(STarget target,
java.lang.Object input)
Implements interface method. |
SHost |
host()
Re-implementation to create/return a suitable SHost. |
protected void |
hostWindowOpened()
Called from openApp(). |
SFacet |
newDebugSwitchLabel(SFacet client)
|
protected java.lang.String |
newDebugText()
|
protected SHost.FacetLayout |
newEmptyDesktopLayout(SHost host,
SContentRootTargeter t,
SFacet surfaceRootFacet)
Provide a empty SHost.FacetLayout. |
protected MountFacet |
newMultiContentFacet(SAreaTarget surfaceRoot)
May return a facet to be attached to the surface root. |
SurfaceServices |
newSimpleServices(MenuFacets contextFacets)
Supplies a simple implementation of SurfaceServices. |
protected java.lang.String |
newTitleBarText()
Implements abstract method. |
protected void |
notifiedFlash(Notice notice)
Called from notify(Notice) when the Notice passed
has Notifying.Impact.FLASH. |
void |
notify(Notice notice)
Respond to the Notice passed. |
void |
openApp()
Overrides superclass implementation. |
void |
runWatched(WatchableOperation r)
Allows runtime exceptions in framework and client code to be handled gracefully, by AppWatcher. |
void |
runWatchedLater(WatchableOperation r)
|
void |
setLayoutTargetsLive(boolean live)
|
protected void |
traceOutput(java.lang.String msg)
Outputs complete trace messages to console or elsewhere. |
| Methods inherited from class facets.core.app.ActionAppSurface |
|---|
contentIsRemovable, getFixedOpeningContentSources, getOpeningContentSources, lazySurfaceRootElements, surfaceRetargeted |
| Methods inherited from class facets.core.app.AppSurface |
|---|
activeContentRootTargeter, addContent, buildRetargeted, cloneActiveRoot, contentNotAdded, findActiveContent, firstContentRoot, getViewerContents, isBuilt, isHeadless, newContenter, newHeadlessHost, removeActiveContent, removeActiveRoot, removeAllContent, replaceSingleContent, revertActiveContent, surfaceRootTargeter, title |
| Methods inherited from class facets.util.Tracer |
|---|
trace, trace, trace, trace, trace, traceDebug, traceDebug, traceObjectText, traceOutputWithClass |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final FacetFactory ff
AppSurface.Contenters
| Constructor Detail |
|---|
public FacetAppSurface(FacetAppSpecifier spec,
FacetFactory ff)
ff - set as ff after being passed to
constructor as AppServices| Method Detail |
|---|
protected final void traceOutput(java.lang.String msg)
TracerDefault prepends helpful classname to message.
traceOutput in class Tracermsg - passed from one of the public methodspublic final void openApp()
AppHost and obtains from it a
suitable Dialogs.
AppWatcher warnings.
appOpened() and returns
appOpened().
openApp in class AppSurface
public final void debugWatch(java.lang.String callName,
boolean providing,
boolean exception)
public final void runWatched(WatchableOperation r)
AppSurfaceAppWatcher.
Default simply runs r
runWatched in class AppSurfacepublic final void runWatchedLater(WatchableOperation r)
protected ActionAppSurface.CachingStyle cachingStyle()
cachingStyle in class ActionAppSurfaceprotected long calculateCacheMb(int maxSafeMb)
calculateCacheMb in class ActionAppSurfaceprotected final MountFacet newMultiContentFacet(SAreaTarget surfaceRoot)
AppSurfaceDefines a tab folder or internal desktop for a multi-content surface - not called for single content as the content root facet is used instead.
newMultiContentFacet in class AppSurfacesurfaceRoot - was (re)created in SSurface.buildRetargeted()public final void notify(Notice notice)
NotifiableNotice passed.
When this method is called, the Notifiable should
respond based on
Notice passed.
notify in interface Notifiablenotify in class ActionAppSurfaceprotected void notifiedFlash(Notice notice)
notify(Notice) when the Notice passed
has Notifying.Impact.FLASH.
No other response is made to such notifications.
Default...
public final SFacet newDebugSwitchLabel(SFacet client)
public final java.lang.String areaTitle(int depth)
public final boolean closeAcceptable(WindowAppHost host)
host - should call if a request to close is made by the app or the toolkit windowpublic final SurfaceServices newSimpleServices(MenuFacets contextFacets)
SurfaceServices.
This method is intended for use in implementations of
AppSurface.Contenter.newContentLayout(SHost, SFacet,
SContentRootTargeter),
to meet the contract of layout creation methods such as
AppHost.newDesktopLayout(SFacet, facets.core.app.AppHost.LayoutFeatures).
It provides a fine example of the closure-like use of anonymous classes,
in that a hidden reference to the enclosing FacetAppSurface is
passed to the SurfaceServices returned.
When this is returned by AppHost.activeServices()
in handleInvalidInput(STarget, Object), code can be executed
using the reference even
though the SurfaceServices was created from within a contenter
and returned by the host.
contextFacets - will ultimately be returned by
getContextMenuFacets()public final MenuFacets getContextMenuFacets()
To ensure the request is met by the active SContenter,
delegates to the SurfaceServices returned by
AppHost.activeServices() in host().
getContextMenuFacets in interface SurfaceServices
public final void handleInvalidInput(STarget target,
java.lang.Object input)
To ensure the request is met by the active SContenter,
delegates to the SurfaceServices returned by
AppHost.activeServices() in host().
handleInvalidInput in interface SurfaceServicestarget - exposed by the facetinput - is known to be invalidpublic final Dialogs dialogs()
Dialogs created during openApp().
dialogs in class ActionAppSurfacepublic SHost host()
SHost.
host in interface SSurfaceAppSurface.isHeadless() returns true,
the return of FacetFactory.newDesktopHost(FacetAppSurface)public final void setLayoutTargetsLive(boolean live)
protected SHost.FacetLayout newEmptyDesktopLayout(SHost host,
SContentRootTargeter t,
SFacet surfaceRootFacet)
AppSurfaceSHost.FacetLayout.
Implements AppSurface.Contenter.newContentLayout(SHost, SFacet, SContentRootTargeter)
on behalf of AppSurface.emptyContent
newEmptyDesktopLayout in class AppSurfaceprotected java.lang.Object getInternalContentSource()
Default is invalid stub.
getInternalContentSource in class ActionAppSurfacepublic FileSpecifier[] getFileSpecifiers()
Called from AppFileValues.getOpenSpecifiers() in FileAppActions
and typically from ViewerContenter.sinkFileSpecifiers();
default returns FileSpecifier.ALL.
protected java.lang.String newTitleBarText()
Default adjusts title bar to shown save warning.
protected final java.lang.String newDebugText()
protected void hostWindowOpened()
openApp().
Default is empty stub.
protected void appOpened()
openApp().
Default is empty stub.
protected void appClosing()
true return from closeAcceptable(WindowAppHost).
Default is empty stub.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||