Repository: incubator-juneau-website Updated Branches: refs/heads/asf-site 89f968700 -> 2f689d14e
Update about page. Project: http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/commit/2f689d14 Tree: http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/tree/2f689d14 Diff: http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/diff/2f689d14 Branch: refs/heads/asf-site Commit: 2f689d14e849edebfe6272f982d4dafb37e2ee5f Parents: 89f9687 Author: JamesBognar <[email protected]> Authored: Mon Jul 3 10:07:35 2017 -0400 Committer: JamesBognar <[email protected]> Committed: Mon Jul 3 10:07:35 2017 -0400 ---------------------------------------------------------------------- content/about.html | 30 +++++++++++++++++++++++--- content/images/Samples_RootResources.png | Bin 62372 -> 171499 bytes 2 files changed, 27 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/blob/2f689d14/content/about.html ---------------------------------------------------------------------- diff --git a/content/about.html b/content/about.html index e40e438..0f06921 100644 --- a/content/about.html +++ b/content/about.html @@ -911,16 +911,40 @@ </p> <br><br><hr> <p> - Navigatable hierarchies of REST resources are easy to set up either programmatically or through annotations: + Navigatable hierarchies of REST resources are easy to set up either programmatically or through annotations. + <br> + The following example is the <code>RootResources</code> class from the REST examples showing how to construct + a grouping of resources using the <code>children()</code> annotation: </p> <p class='bcode'> <ja>@RestResource</ja>( path=<js>"/"</js>, title=<js>"Root resources"</js>, - description=<js>"This is an example of a router resource that is used to access other resources."</js>, - pageLinks=<js>"{options:'?method=OPTIONS',source:'$C{Source/gitHub}/org/apache/juneau/rest/example/RootResources.java'}"</js>, + description=<js>"Example of a router resource page."</js>, + widgets={ + PoweredByApacheWidget.<jk>class</jk>, + ContentTypeMenuItem.<jk>class</jk> + }, + htmldoc=<ja>@HtmlDoc</ja>( + links=<js>"{"</js> + + <js>"options:'?method=OPTIONS',"</js> + + <js>"contentTypes:'$W{contentTypeMenuItem}',"</js> + + <js>"source:'$C{Source/gitHub}/org/apache/juneau/examples/rest/RootResources.java'"</js> + + <js>"}"</js>, + aside=<js>""</js> + + <js>"<div style='max-width:400px' class='text'>"</js> + + <js>" <p>This is an example of a 'router' page that serves as a jumping-off point to child resources.</p>"</js> + + <js>" <p>Resources can be nested arbitrarily deep through router pages.</p>"</js> + + <js>" <p>Note the <span class='link'>OPTIONS</span> link provided that lets you see the generated swagger doc for this page.</p>"</js> + + <js>" <p>Also note the <span class='link'>SOURCE</span> link on these pages to view the source code for the page.</p>"</js> + + <js>" <p>All content on pages in the UI are serialized POJOs. In this case, it's a serialized array of beans with 2 properties, 'name' and 'description'.</p>"</js> + + <js>" <p>Other features (such as this aside) are added through annotations.</p>"</js> + + <js>"</div>"</js>, + footer=<js>"$W{poweredByApache}"</js> + ), children={ HelloWorldResource.<jk>class</jk>, + PetStoreResource.<jk>class</jk>, SystemPropertiesResource.<jk>class</jk>, MethodExampleResource.<jk>class</jk>, RequestEchoResource.<jk>class</jk>, http://git-wip-us.apache.org/repos/asf/incubator-juneau-website/blob/2f689d14/content/images/Samples_RootResources.png ---------------------------------------------------------------------- diff --git a/content/images/Samples_RootResources.png b/content/images/Samples_RootResources.png index 62408e2..e43d31e 100644 Binary files a/content/images/Samples_RootResources.png and b/content/images/Samples_RootResources.png differ
