ariba.ui.aribaweb.util
Class AWStaticSiteGenerator
java.lang.Object
ariba.ui.aribaweb.util.AWStaticSiteGenerator
public class AWStaticSiteGenerator
- extends java.lang.Object
Used to statically render a site by internally "spidering".
How it works:
- As page is rendered, actions are *immediately evaluated* to get the destination component.
- The URL for the action results are then determined (by asking the component its Naming.staticPath()
(if it knows how to determine is static URL from its state) or using the template name (if not).
- Components with previously unseeing URLs are enqueued for generation as well.
- Resources urls (for .css, .js, and images) trigger callbacks. Their files are copied and an aliased
url (relative to the current component's relative path) is returned.
- Referenced .css files are scanned for additional resource ("url(...)") references, and these are
processed as well.
Limitations:
This is only intended for a limited class of (essentially stateless) navigation only sites.
E.g.:
- No Dynamic forms
- No components that update internal state and return same component (e.g. internal tab sets)
Note that this class does have a main() and can be used to generate a site for an appropriately formatted
source directory (without compiling it), as long as the site uses only static .awls, expr, and inline groovy.
This support is used to generate the aribaweb.org static website.
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AWStaticSiteGenerator
public AWStaticSiteGenerator(java.io.File outputDir)
formatUrlForResource
public java.lang.String formatUrlForResource(java.lang.String urlPrefix,
AWResource resource,
boolean forCache)
note
public java.lang.String note(AWComponent component)
didCreateRequestContext
public void didCreateRequestContext(AWRequestContext requestContext)
processFromRoot
public void processFromRoot(AWComponent startPage)
main
public static void main(java.lang.String[] args)
AribaWeb User Interface Development Framework
Copyright © 2000-2014 Ariba, Inc. All Rights Reserved.