Replaced latest version with variable Renamed macros.vtl to includes.vtl
Project: http://git-wip-us.apache.org/repos/asf/shiro-site/repo Commit: http://git-wip-us.apache.org/repos/asf/shiro-site/commit/07b38e48 Tree: http://git-wip-us.apache.org/repos/asf/shiro-site/tree/07b38e48 Diff: http://git-wip-us.apache.org/repos/asf/shiro-site/diff/07b38e48 Branch: refs/heads/master Commit: 07b38e480cb347322ee054edfaa5db7c05473e3d Parents: 276b79c Author: Brian Demers <[email protected]> Authored: Wed Oct 19 10:15:21 2016 -0400 Committer: Brian Demers <[email protected]> Committed: Wed Oct 19 10:15:21 2016 -0400 ---------------------------------------------------------------------- 10-minute-tutorial.html.vtl | 8 +- documentation.html | 57 -- documentation.html.vtl | 59 +++ download.html | 1086 ------------------------------------- download.html.vtl | 1088 ++++++++++++++++++++++++++++++++++++++ templates/default.vtl | 2 +- templates/includes.vtl | 8 + templates/macros.vtl | 6 - templates/versions.vtl | 2 + 9 files changed, 1162 insertions(+), 1154 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/shiro-site/blob/07b38e48/10-minute-tutorial.html.vtl ---------------------------------------------------------------------- diff --git a/10-minute-tutorial.html.vtl b/10-minute-tutorial.html.vtl index 49dd68e..aa8d8b7 100644 --- a/10-minute-tutorial.html.vtl +++ b/10-minute-tutorial.html.vtl @@ -1,4 +1,4 @@ -#parse("templates/macros.vtl") +#parse("templates/includes.vtl") <h1><a name="10MinuteTutorial-10MinuteTutorialonApacheShiro"></a>10 Minute Tutorial on Apache Shiro</h1> @@ -51,13 +51,13 @@ <ol> <li>Ensure you have JDK 1.6+ and Maven 3.0.3+ installed.</li> <li>Download the lastest "Source Code Distribution" from the <a href="download.html" title="Download">Download</a> - page. In this example, we're using the 1.3.2 release distribution. + page. In this example, we're using the ${latestRelease} release distribution. </li> <li>Unzip the source package: <div class="code panel" style="border-width: 1px;"> <div class="codeContent panelContent"> <pre class="code-java"> -> unzip shiro-root-1.3.2-source-release.zip +> unzip shiro-root-${latestRelease}-source-release.zip </pre> </div> </div> @@ -66,7 +66,7 @@ <div class="code panel" style="border-width: 1px;"> <div class="codeContent panelContent"> <pre class="code-java"> -> cd shiro-root-1.3.2/samples/quickstart +> cd shiro-root-${latestRelease}/samples/quickstart </pre> </div> </div> http://git-wip-us.apache.org/repos/asf/shiro-site/blob/07b38e48/documentation.html ---------------------------------------------------------------------- diff --git a/documentation.html b/documentation.html deleted file mode 100644 index 99132e5..0000000 --- a/documentation.html +++ /dev/null @@ -1,57 +0,0 @@ -<h1><a name="Documentation-ApacheShiroDocumentation"></a>Apache Shiro Documentation</h1> - -<h3><a name="Documentation-Introduction"></a>Introduction</h3> -<p>Helpful if read in order:</p> -<ul> - <li><a class="external-link" href="http://www.infoq.com/articles/apache-shiro" rel="nofollow">Application Security - with Apache Shiro</a> - full intro article on InfoQ.com - </li> - <li><a href="10-minute-tutorial.html" title="10 Minute Tutorial">10 Minute Tutorial</a></li> - <li><a href="webapp-tutorial.html" title="Beginner's Webapp Tutorial">Beginner's Webapp Tutorial: a step-by-step tutorial to enable Shiro in a web application</a></li> -</ul> - -<h2><a name="Documentation-ApacheShiroReferenceandAPI"></a>Apache Shiro Reference and API</h2> - -<h3><a name="Documentation-ReferenceManual"></a>Reference Manual</h3> -<ul> - <li><a href="reference.html" title="Reference">Reference Manual</a></li> -</ul> - - -<h3><a name="Documentation-GuidesimportantShiroconcepts%3A"></a>Guides - important Shiro concepts:</h3> -<ul> - <li><a href="10-minute-tutorial.html" title="10 Minute Tutorial">10 Minute Tutorial</a></li> - <li><a href="webapp-tutorial.html">Beginner's Webapp Tutorial: a step-by-step tutorial to enable Shiro in a web application</a></li> - <li><a href="java-authentication-guide.html" title="Java Authentication Guide">Authentication Guide</a></li> - <li><a href="java-authorization-guide.html" title="Java Authorization Guide">Authorization Guide</a></li> - <li>Community-contributed <a href="articles.html" title="Articles">Articles</a></li> -</ul> - -<h3><a name="Documentation-CurrentRelease"></a>Current Release</h3> -<p>Apache Shiro 1.3.2 (<a href="download.html" title="Download">Download</a>)</p> -<ul> - <li><a class="external-link" href="static/1.3.2/apidocs">API</a> (JavaDoc)</li> - <li><a class="external-link" href="static/1.3.2/xref/">Browse Source</a> (XREF)</li> - <li><a class="external-link" href="static/1.3.2/">Maven Static Site</a></li> -<!-- <li><a class="external-link" - href="https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12310950&version=12323469&styleName=Html&projectId=12310950">Release - Notes</a></li> --> -</ul> - -<!-- -<h3><a name="Documentation-PreviousReleases"></a>Previous Releases</h3> -<p>Apache Shiro 1.0.0-incubating (<a class="external-link" href="http://svn.apache.org/repos/asf/shiro/tags/shiro-root-1.0.0-incubating">Build from source</a>)</p> -<ul><li><a class="external-link" href="static/1.0.0-incubating/apidocs">API</a> (JavaDoc)</li><li><a class="external-link" href="static/1.0.0-incubating/xref/">Browse Source</a> (XREF)</li><li><a class="external-link" href="static/1.0.0-incubating/">Maven Static Site</a></li><li><a class="external-link" href="https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12310950&styleName=Html&version=12314078">Release Notes</a></li></ul> --> - - -<h2><a name="Documentation-Lendahandwithdocumentation"></a>Lend a hand with documentation </h2> - -<p>While we hope this documentation helps you with the work you're doing with Apache Shiro, the community is improving - and expanding the documentation all the time. If you'd like to help the Shiro project, please consider corrected, - expanding, or adding documentation where you see a need. Every little bit of help you provide expands the community - and in turn improves Shiro. </p> - -<p>The easiest way to contribute your documentation is to send it to the <a class="external-link" - href="http://shiro-user.582556.n2.nabble.com/" - rel="nofollow">User Forum</a> or the <a - href="mailing-lists.html" title="Mailing Lists">User Mailing List</a>.</p> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/shiro-site/blob/07b38e48/documentation.html.vtl ---------------------------------------------------------------------- diff --git a/documentation.html.vtl b/documentation.html.vtl new file mode 100644 index 0000000..e04ab1c --- /dev/null +++ b/documentation.html.vtl @@ -0,0 +1,59 @@ +#parse("templates/includes.vtl") + +<h1><a name="Documentation-ApacheShiroDocumentation"></a>Apache Shiro Documentation</h1> + +<h3><a name="Documentation-Introduction"></a>Introduction</h3> +<p>Helpful if read in order:</p> +<ul> + <li><a class="external-link" href="http://www.infoq.com/articles/apache-shiro" rel="nofollow">Application Security + with Apache Shiro</a> - full intro article on InfoQ.com + </li> + <li><a href="10-minute-tutorial.html" title="10 Minute Tutorial">10 Minute Tutorial</a></li> + <li><a href="webapp-tutorial.html" title="Beginner's Webapp Tutorial">Beginner's Webapp Tutorial: a step-by-step tutorial to enable Shiro in a web application</a></li> +</ul> + +<h2><a name="Documentation-ApacheShiroReferenceandAPI"></a>Apache Shiro Reference and API</h2> + +<h3><a name="Documentation-ReferenceManual"></a>Reference Manual</h3> +<ul> + <li><a href="reference.html" title="Reference">Reference Manual</a></li> +</ul> + + +<h3><a name="Documentation-GuidesimportantShiroconcepts%3A"></a>Guides - important Shiro concepts:</h3> +<ul> + <li><a href="10-minute-tutorial.html" title="10 Minute Tutorial">10 Minute Tutorial</a></li> + <li><a href="webapp-tutorial.html">Beginner's Webapp Tutorial: a step-by-step tutorial to enable Shiro in a web application</a></li> + <li><a href="java-authentication-guide.html" title="Java Authentication Guide">Authentication Guide</a></li> + <li><a href="java-authorization-guide.html" title="Java Authorization Guide">Authorization Guide</a></li> + <li>Community-contributed <a href="articles.html" title="Articles">Articles</a></li> +</ul> + +<h3><a name="Documentation-CurrentRelease"></a>Current Release</h3> +<p>Apache Shiro ${latestRelease} (<a href="download.html" title="Download">Download</a>)</p> +<ul> + <li><a class="external-link" href="static/${latestRelease}/apidocs">API</a> (JavaDoc)</li> + <li><a class="external-link" href="static/${latestRelease}/xref/">Browse Source</a> (XREF)</li> + <li><a class="external-link" href="static/${latestRelease}/">Maven Static Site</a></li> +<!-- <li><a class="external-link" + href="https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12310950&version=12323469&styleName=Html&projectId=12310950">Release + Notes</a></li> --> +</ul> + +<!-- +<h3><a name="Documentation-PreviousReleases"></a>Previous Releases</h3> +<p>Apache Shiro 1.0.0-incubating (<a class="external-link" href="http://svn.apache.org/repos/asf/shiro/tags/shiro-root-1.0.0-incubating">Build from source</a>)</p> +<ul><li><a class="external-link" href="static/1.0.0-incubating/apidocs">API</a> (JavaDoc)</li><li><a class="external-link" href="static/1.0.0-incubating/xref/">Browse Source</a> (XREF)</li><li><a class="external-link" href="static/1.0.0-incubating/">Maven Static Site</a></li><li><a class="external-link" href="https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12310950&styleName=Html&version=12314078">Release Notes</a></li></ul> --> + + +<h2><a name="Documentation-Lendahandwithdocumentation"></a>Lend a hand with documentation </h2> + +<p>While we hope this documentation helps you with the work you're doing with Apache Shiro, the community is improving + and expanding the documentation all the time. If you'd like to help the Shiro project, please consider corrected, + expanding, or adding documentation where you see a need. Every little bit of help you provide expands the community + and in turn improves Shiro. </p> + +<p>The easiest way to contribute your documentation is to send it to the <a class="external-link" + href="http://shiro-user.582556.n2.nabble.com/" + rel="nofollow">User Forum</a> or the <a + href="mailing-lists.html" title="Mailing Lists">User Mailing List</a>.</p> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/shiro-site/blob/07b38e48/download.html ---------------------------------------------------------------------- diff --git a/download.html b/download.html deleted file mode 100644 index fe360b8..0000000 --- a/download.html +++ /dev/null @@ -1,1086 +0,0 @@ -<h1><a name="Download-DownloadApacheShiro"></a>Download Apache Shiro</h1> - -<table align="right" width="275" style="margin-left: 20px; margin-bottom: 20px; border-style: solid; border-width: 2px; border-color: navy" cellpadding="10px"> - -<tr> -<td> -<div id="border"> - <h2>Related Content</h2> - - <h3><a href="get-started.html">Getting Started</a></h3> - <p>Resources, guides and tutorials for new Shiro users. </br><span style="font-size:11"><a href="get-started.html">Read More >></a></span></p> - - <h3><a href="10-minute-tutorial.html">10-Minute Shiro Tutorial</a></h3> - <p>Try Apache Shiro for yourself in under 10 minutes. </br><span style="font-size:11"><a href="10-minute-tutorial.html">Read More >></a></span></p> - - <h3><a href="webapp-tutorial.html">Web App Tutorial</a></h3> - <p>Step-by-step tutorial for securing a web application with Shiro. </br><span style="font-size:11"><a href="webapp-tutorial.html">Read More >></a></span></p> - - <h3><a href="java-authentication-guide.html">Java Authentication Guide</a></h3> - <p>Learn how Authentication in Java is performed in Shiro. </br><span style="font-size:11"><a href="java-authentication-guide.html">Read More >></a></span></p> - - <h3><a href="java-authorization-guide.html">Java Authorization Guide</a></h3> - <p>Learn how Shiro handles access control in Java. </br><span style="font-size:11"><a href="java-authorization-guide.html">Read More >></a></span></p> - -</div> -</td> -</tr> -</table> - -<p>Apache Shiro 1.3.2 is the current stable release (Java 1.6+ JVM).</p> - -<p>To download Shiro please follow the instructions below.</p> - -<h3>Code Signatures</h3> - -<p>You may <a class="external-link" href="http://www.apache.org/dev/release-signing.html#verifying-signature">verify the - authenticity</a> of all artifacts below by using the PGP <a class="external-link" - href="http://www.apache.org/dist/shiro/KEYS">KEYS</a> - file. </p> - -<h3>Releases</h3> - -<div> - <ul> - <li> - <a href="#latest">Latest Stable Release (1.3.2)</a> - <ul> - <li><a href="#latestBinary">1.3.2 Binary Distribution</a></li> - <li><a href="#latestSource">1.3.2 Source Code Distribution</a></li> - <li><a href="#latestGit">1.3.2 Git Source repository</a></li> - </ul> - </li> - <li><a href="#previous">Previous Releases</a> - <ul> - <li><a href="#1.2.xBinary">1.2.6</a></li> - <ul> - <li><a href="#1.2.xBinary">1.2.6 Binary Distribution</a></li> - <li><a href="#1.2.xSource">1.2.6 Source Code Distribution</a></li> - <li><a href="#1.2.xGit">1.2.6 Git Source repository</a></li> - </ul> - </ul> - <ul> - <li><a href="#1.1.0Binary">1.1.0</a></li> - <ul> - <li><a href="#1.1.0Binary">1.1.0 Binary Distribution</a></li> - <li><a href="#1.1.0Source">1.1.0 Source Code Distribution</a></li> - <li><a href="#1.1.0Git">1.1.0 Git Source repository</a></li> - </ul> - </ul> - </li> - </ul> -</div> - - -<h2><a name="latest"></a>Latest Stable Release (1.3.2)</h2> - -<h3><a name="latestBinary"></a>1.3.2 Binary Distribution</h3> - -<p>Associated documentation can be found <a href="documentation.html" title="Documentation">here</a></p> - -<p>To download the files directly as one .jar file just click the link in the "Artifact" column. If you would like - acquire Shiro through Maven, then please use the markup listed under "Maven Usage"</p> - -<p> -</p> -<div class="table-wrap"> - - <table class="confluenceTable" id="table-latest"> - <tbody> - <tr> - <th colspan="1" rowspan="1" class="confluenceTh"> Artifact</th> - <th colspan="1" rowspan="1" class="confluenceTh"> Maven Usage</th> - <th colspan="1" rowspan="1" class="confluenceTh"> Notes</th> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-all/1.3.2/shiro-all-1.3.2.jar">shiro-all</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"><b>Not Recommended</b></td> - <td colspan="1" rowspan="1" class="confluenceTd"> Includes all binary functionality for Shiro (without - dependencies), useful in certain build environments (e.g. Ant). However, this is <b>NOT</b> - recommended in Maven builds as it does not retain correct dependency metadata, which can lead to - Maven working incorrectly. For Maven builds, it is <b>highly</b> recommended to specify individual - modules listed below as you require them. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-core/1.3.2/shiro-core-1.3.2.jar">shiro-core</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-core</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Required in all environments. <a class="external-link" - href="http://slf4j.org/">Slf4j</a>'s - <tt>slf4j-api</tt> jar and one of its binding jars is required. <tt>commons-beanutils</tt> is - required only if using INI config. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-web/1.3.2/shiro-web-1.3.2.jar">shiro-web</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-web</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables support for web-based applications.</td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-aspectj/1.3.2/shiro-aspectj-1.3.2.jar">shiro-aspectj</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-aspectj</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.eclipse.org/aspectj/">AspectJ</a> support for - Shiro AOP and Annotations. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-cas/1.3.2/shiro-cas-1.3.2.jar">shiro-cas</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-cas</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables Jasig <a class="external-link" - href="http://www.jasig.org/cas">CAS</a> support. - <div class="warning"> - <span>NOTE:</span> - Shiro-CAS support is deprecated, support has been moved to the Apache Shiro based <a href="https://github.com/bujiio/buji-pac4j">buji-pac4j</a> project. - </div> - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-ehcache/1.3.2/shiro-ehcache-1.3.2.jar">shiro-ehcache</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-ehcache</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://ehcache.org">Ehcache</a>-based - famework caching. - </td> - </tr> - - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-hazelcast/1.3.2/shiro-hazelcast-1.3.2.jar">shiro-hazelcast</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-hazelcast</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://hazelcast.org">Hazelcast</a>-based - famework caching. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-features/1.3.2/shiro-features-1.3.2-features.xml">shiro-features</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-features</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> OSGi / <a class="external-link" - href="http://karaf.apache.org/">Apache - Karaf</a> integration. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-guice/1.3.2/shiro-guice-1.3.2.jar">shiro-guice</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-guice</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://code.google.com/p/google-guice/">Google Guice</a> - integration. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-quartz/1.3.2/shiro-quartz-1.3.2.jar">shiro-quartz</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-quartz</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.quartz-scheduler.org/">Quartz</a>-based scheduling - for Shiro native session validation. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-spring/1.3.2/shiro-spring-1.3.2.jar">shiro-spring</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-spring</artifactId> - <version>1.3.2</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.springsource.org/about">Spring Framework</a> - integration. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/tools/shiro-tools-hasher/1.3.2/shiro-tools-hasher-1.3.2-cli.jar">shiro-tools-hasher-cli</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"><b>Not Relevant</b></td> - <td colspan="1" rowspan="1" class="confluenceTd"> A command-line program to perform hashing (MD5, SHA, - etc) for files, streams and passwords. Note that this is a command line program and not intended to - be <br clear="none"> - used as a Maven/program dependency. It is intended to be downloaded and executed: - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"> -java -jar shiro-tools-hasher-1.3.2-cli.jar -</pre> - </div> - </div> - </td> - </tr> - </tbody> - </table> -</div> - - -<h3><a name="latestSource"></a>1.3.2 Source Code Distribution</h3> - -<p>The source bundle requires JDK 1.6 and Maven 3.0.3+ to build:</p> - -<p><a class="external-link" href="http://www.apache.org/dyn/closer.cgi/shiro/1.3.2/shiro-root-1.3.2-source-release.zip">zip</a> - (<a class="external-link" - href="http://www.apache.org/dyn/closer.cgi/shiro/1.3.2/shiro-root-1.3.2-source-release.zip.asc">pgp</a>, <a - class="external-link" - href="http://www.apache.org/dyn/closer.cgi/shiro/1.3.2/shiro-root-1.3.2-source-release.zip.md5">md5</a>, <a - class="external-link" - href="http://www.apache.org/dyn/closer.cgi/shiro/1.3.2/shiro-root-1.3.2-source-release.zip.sha1">sha1</a>) -</p> - -<h3><a name="latestGit"></a>1.3.2 Git Source repository</h3> - -<p>The source can be cloned anonymously from Git with this command:</p> -<div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"> -git clone https:<span class="code-comment">//github.com/apache/shiro.git</span> -git checkout shiro-root-1.3.2 -b shiro-root-1.3.2 -</pre> - </div> -</div> - -<h2><a name="previous"></a>Previous Releases</h2> - - -<h3><a name="1.2.xBinary"></a>1.2.6 Binary Distribution</h3> - -<p>Associated documentation can be found <a href="documentation.html" title="Documentation">here</a></p> - -<p>To download the files directly as one .jar file just click the link in the "Artifact" column. If you would like - acquire Shiro through Maven, then please use the markup listed under "Maven Usage"</p> - -<p> -</p> -<div class="table-wrap"> - - <table class="confluenceTable" id="table-1.2.x"> - <tbody> - <tr> - <th colspan="1" rowspan="1" class="confluenceTh"> Artifact</th> - <th colspan="1" rowspan="1" class="confluenceTh"> Maven Usage</th> - <th colspan="1" rowspan="1" class="confluenceTh"> Notes</th> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-all/1.2.6/shiro-all-1.2.6.jar">shiro-all</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"><b>Not Recommended</b></td> - <td colspan="1" rowspan="1" class="confluenceTd"> Includes all binary functionality for Shiro (without - dependencies), useful in certain build environments (e.g. Ant). However, this is <b>NOT</b> - recommended in Maven builds as it does not retain correct dependency metadata, which can lead to - Maven working incorrectly. For Maven builds, it is <b>highly</b> recommended to specify individual - modules listed below as you require them. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-core/1.2.6/shiro-core-1.2.6.jar">shiro-core</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-core</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Required in all environments. <a class="external-link" - href="http://slf4j.org/">Slf4j</a>'s - <tt>slf4j-api</tt> jar and one of its binding jars is required. <tt>commons-beanutils</tt> is - required only if using INI config. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-web/1.2.6/shiro-web-1.2.6.jar">shiro-web</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-web</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables support for web-based applications.</td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-aspectj/1.2.6/shiro-aspectj-1.2.6.jar">shiro-aspectj</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-aspectj</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.eclipse.org/aspectj/">AspectJ</a> support for - Shiro AOP and Annotations. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-cas/1.2.6/shiro-cas-1.2.6.jar">shiro-cas</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-cas</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables Jasig <a class="external-link" - href="http://www.jasig.org/cas">CAS</a> support. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-ehcache/1.2.6/shiro-ehcache-1.2.6.jar">shiro-ehcache</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-ehcache</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://ehcache.org">Ehcache</a>-based - famework caching. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-features/1.2.6/shiro-features-1.2.6-features.xml">shiro-features</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-features</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> OSGi / <a class="external-link" - href="http://karaf.apache.org/">Apache - Karaf</a> integration. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-guice/1.2.6/shiro-guice-1.2.6.jar">shiro-guice</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-guice</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://code.google.com/p/google-guice/">Google Guice</a> - integration. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-quartz/1.2.6/shiro-quartz-1.2.6.jar">shiro-quartz</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-quartz</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.quartz-scheduler.org/">Quartz</a>-based scheduling - for Shiro native session validation. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-spring/1.2.6/shiro-spring-1.2.6.jar">shiro-spring</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-spring</artifactId> - <version>1.2.6</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.springsource.org/about">Spring Framework</a> - integration. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/tools/shiro-tools-hasher/1.2.6/shiro-tools-hasher-1.2.6-cli.jar">shiro-tools-hasher-cli</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"><b>Not Relevant</b></td> - <td colspan="1" rowspan="1" class="confluenceTd"> A command-line program to perform hashing (MD5, SHA, - etc) for files, streams and passwords. Note that this is a command line program and not intended to - be <br clear="none"> - used as a Maven/program dependency. It is intended to be downloaded and executed: - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"> -java -jar shiro-tools-hasher-1.2.6-cli.jar -</pre> - </div> - </div> - </td> - </tr> - </tbody> - </table> -</div> - - -<h3><a name="1.2.xSource"></a>1.2.6 Source Code Distribution</h3> - -<p>The source bundle requires JDK 1.6 and Maven 3.0.3+ to build:</p> - -<p><a class="external-link" href="http://www.apache.org/dyn/closer.cgi/shiro/1.2.6/shiro-root-1.2.6-source-release.zip">zip</a> - (<a class="external-link" - href="http://www.apache.org/dyn/closer.cgi/shiro/1.2.6/shiro-root-1.2.6-source-release.zip.asc">pgp</a>, <a - class="external-link" - href="http://www.apache.org/dyn/closer.cgi/shiro/1.2.6/shiro-root-1.2.6-source-release.zip.md5">md5</a>, <a - class="external-link" - href="http://www.apache.org/dyn/closer.cgi/shiro/1.2.6/shiro-root-1.2.6-source-release.zip.sha1">sha1</a>) -</p> - -<h3><a name="1.2.xGit"></a>1.2.6 Git Source repository</h3> - -<p>The source can be cloned anonymously from Git with this command:</p> -<div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"> -git clone https:<span class="code-comment">//github.com/apache/shiro.git</span> -git checkout shiro-root-1.2.6 -b shiro-root-1.2.6 -</pre> - </div> -</div> - - -<h3><a name="1.1.0"></a>1.1.0</h3> - -<h4><a name="1.1.0Binary"></a>1.1.0 Binary Distribution</h4> - -<p>Associated documentation can be found <a href="documentation.html" title="Documentation">here</a></p> - -<p>To download the files directly as one .jar file just click the link in the "Artifact" column. If you would like - acquire Shiro through Maven, then please use the markup listed under "Maven Usage"</p> - -<p> -</p> -<div class="table-wrap"> - - <table class="confluenceTable" id="table-1.1.0"> - <tbody> - <tr> - <th colspan="1" rowspan="1" class="confluenceTh"> Artifact</th> - <th colspan="1" rowspan="1" class="confluenceTh"> Maven Usage</th> - <th colspan="1" rowspan="1" class="confluenceTh"> Notes</th> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-all/1.1.0/shiro-all-1.1.0.jar">shiro-all</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"><b>Not Recommended</b></td> - <td colspan="1" rowspan="1" class="confluenceTd"> Includes all binary functionality for Shiro (without - dependencies), useful in certain build environments (e.g. Ant). However, this is <b>NOT</b> - recommended in Maven builds as it does not retain correct dependency metadata, which can lead to - Maven working incorrectly. For Maven builds, it is <b>highly</b> recommended to specify individual - modules listed below as you require them. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-core/1.1.0/shiro-core-1.1.0.jar">shiro-core</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-core</artifactId> - <version>1.1.0</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Required in all environments. <a class="external-link" - href="http://slf4j.org/">Slf4j</a>'s - <tt>slf4j-api</tt> jar and one of its binding jars is required. <tt>commons-beanutils</tt> is - required only if using INI config. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-web/1.1.0/shiro-web-1.1.0.jar">shiro-web</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-web</artifactId> - <version>1.1.0</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables support for web-based applications.</td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-aspectj/1.1.0/shiro-aspectj-1.1.0.jar">shiro-aspectj</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-aspectj</artifactId> - <version>1.1.0</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.eclipse.org/aspectj/">AspectJ</a> support for - Shiro AOP and Annotations. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-ehcache/1.1.0/shiro-ehcache-1.1.0.jar">shiro-ehcache</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-ehcache</artifactId> - <version>1.1.0</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://ehcache.org">Ehcache</a>-based - famework caching. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-quartz/1.1.0/shiro-quartz-1.1.0.jar">shiro-quartz</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-quartz</artifactId> - <version>1.1.0</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.quartz-scheduler.org/">Quartz</a>-based scheduling - for Shiro native session validation. - </td> - </tr> - <tr> - <td colspan="1" rowspan="1" class="confluenceTd"><a class="external-link" - href="http://repo1.maven.org/maven2/org/apache/shiro/shiro-spring/1.1.0/shiro-spring-1.1.0.jar">shiro-spring</a></td> - <td colspan="1" rowspan="1" class="confluenceTd"> - <div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"><dependency> - <groupId>org.apache.shiro</groupId> - <artifactId>shiro-spring</artifactId> - <version>1.1.0</version> -</dependency></pre> - </div> - </div> - </td> - <td colspan="1" rowspan="1" class="confluenceTd"> Enables <a class="external-link" - href="http://www.springsource.org/about">Spring Framework</a> - integration. - </td> - </tr> - </tbody> - </table> -</div> - - -<h4><a name="1.1.0Source"></a>1.1.0 Source Code Distribution</h4> - -<p>The 1.1.0 source bundle requires JDK 1.5+ and Maven 2.2+ to build:</p> - -<p><a class="external-link" - href="http://archive.apache.org/dist/shiro/1.1.0/shiro-root-1.1.0-source-release.zip">zip</a> (<a - class="external-link" href="http://archive.apache.org/dist/shiro/1.1.0/shiro-root-1.1.0-source-release.zip.asc">pgp</a>, - <a class="external-link" href="http://archive.apache.org/dist/shiro/1.1.0/shiro-root-1.1.0-source-release.zip.md5">md5</a>, - <a class="external-link" href="http://archive.apache.org/dist/shiro/1.1.0/shiro-root-1.1.0-source-release.zip.sha1">sha1</a>) -</p> - -<h4><a name="1.1.0Git"></a>1.1.0 Git Source repository</h4> - -<p>The source can be cloned anonymously from Git with this command:</p> -<div class="code panel" style="border-width: 1px;"> - <div class="codeContent panelContent"> -<pre class="code-java"> -git clone https:<span class="code-comment">//github.com/apache/shiro.git</span> -git checkout shiro-root-1.1.0 -b shiro-root-1.1.0 -</pre> - </div> -</div> - - -<script type="text/javascript"> <!-- -//Copyright(c)2005,2010 Bob Swift and other contributors. All rights reserved. -function getElementInnerText(element) { - var str = ""; - for (var i = 0; i < element.childNodes.length; i++) { - switch (element.childNodes.item(i).nodeType) { - case 1: - str += getElementInnerText(element.childNodes.item(i)); - break; - case 3: - str += element.childNodes.item(i).nodeValue; - break; - } - } - return str; -} -function trimSafe(v) { - return((v == undefined) || (v == null)) ? "" : v.Trim(); -} -String.prototype.Trim = new Function("return this.replace(/^\\s+|\\s+$/g,'')"); -function compareNumber(v1, v2) { - if (isNaN(v2)) { - if (isNaN(v1))return 0; - return-1; - } - if (v1 < v2)return-1; - if (v1 == v2)return 0; - return 1; -} -function compareSeparatedNumber(v1, v2) { - for (i = 0; (i < v1.length) && (i < v2.length); i++) { - var result = compareNumber(parseInt(v1[i]), parseInt(v2[i])); - if (result != 0)return result; - } - if (v1.length < v2.length)return-1; - if (v2.length < v1.length)return 1; - return 0; -} -function sortByCell(sortCell, firstDataRowIndex, footingCount) { - var compareFunction; - var valueParser; - compareFunction = compareNumber; - if (sortCell.columnType == "I") { - valueParser = function (value) { - return parseInt(getElementInnerText(value)); - }; - } else if (sortCell.columnType == "F") { - valueParser = function (value) { - return parseFloat(getElementInnerText(value)); - }; - } else if (sortCell.columnType == "C") { - valueParser = function (value) { - return parseFloat(getElementInnerText(value).replace(/[^\d\.\,\-]*([\d\.\,\-*]*).*/, '$1')); - }; - } else if (sortCell.columnType.charAt(0) == 'D') { - if (Date.parseString) { - valueParser = function (value) { - var date = Date.parseString(trimSafe(getElementInnerText(value)), sortCell.columnType.substring(1)); - return((date == null) ? NaN : date.getTime()); - }; - } else { - valueParser = function (value) { - return Date.parse(getElementInnerText(value)); - }; - } - } else if ((sortCell.columnType == "/") || (sortCell.columnType == ".") || (sortCell.columnType == "-") || (sortCell.columnType == ":")) { - compareFunction = compareSeparatedNumber; - valueParser = function (value) { - return getElementInnerText(value).split(sortCell.columnType); - }; - } else if (sortCell.columnType == "A") { - valueParser = function (value) { - return 0; - }; - } else { - compareFunction = function (v1, v2) { - if (v1 < v2)return-1; - if (v1 == v2)return 0; - return 1; - }; - valueParser = function (value) { - return trimSafe(getElementInnerText(value)).toUpperCase(); - }; - } - var headRowCount = (sortCell.sortTable.tHead == null) ? 0 : sortCell.sortTable.tHead.rows.length; - firstDataRowIndex = firstDataRowIndex - headRowCount; - var table = sortCell.sortTable.tBodies[0]; - var rowCount = table.rows.length - firstDataRowIndex - footingCount; - var map = Array(rowCount); - var values = Array(rowCount); - var compareTest = (sortCell.sortDescending ? -1 : 1); - sortCell.sortDescending = !sortCell.sortDescending; - var firstCell = (((sortCell.sortTable.tHead == null) || (sortCell.sortTable.tHead.rows.length == 0)) ? table.rows[0].cells[sortCell.columnIndex] : sortCell.sortTable.tHead.rows[0].cells[sortCell.columnIndex]); - if ((firstCell != null) && (firstCell.sortTable != null) && (firstCell.sortTable != undefined) && (firstCell.sortTable.sortImage != null) && (firstCell.sortTable.sortImage != undefined)) { - firstCell.sortTable.sortImage.setAttribute("src", firstCell.sortDescending ? firstCell.sortTable.sortAttributeDescending : firstCell.sortTable.sortAttributeAscending); - firstCell.appendChild(firstCell.sortTable.sortImage); - } - var i; - for (i = 0; i < rowCount; i++) { - map[i] = sortCell.sortFirstTime ? i : (rowCount - 1 - i); - var row = table.rows[i + firstDataRowIndex]; - var cellValue = row.cells[sortCell.columnIndex]; - values[i] = valueParser(cellValue); - } - sortCell.sortFirstTime = false; - var didSwap; - do { - didSwap = false; - for (i = 0; i < rowCount - 1; i++) { - if (compareFunction(values[map[i]], values[map[i + 1]]) == compareTest) { - saveIndex = map[i]; - map[i] = map[i + 1]; - map[i + 1] = saveIndex; - didSwap = true; - } - } - } while (didSwap); - var tableRows = new Array(); - for (i = 0; i < rowCount + footingCount; i++) { - tableRows.push(table.rows[i + firstDataRowIndex]); - } - for (i = 0; i < rowCount + footingCount; i++) { - table.removeChild(tableRows[i]); - } - for (i = 0; i < rowCount; i++) { - var row = tableRows[map[i]]; - table.appendChild(row); - if (row.autoNumber) { - row.cells[0].innerHTML = i + 1; - } - } - for (i = 0; i < footingCount; i++) { - table.appendChild(tableRows[i + rowCount]); - } -} -function enableSortOnCell(cell, columnIndex, table, columnTypes, customize) { - cell.style.cursor = "pointer"; - cell.sortTable = table; - cell.sortFirstTime = true; - cell.sortDescending = false; - cell.columnIndex = (customize.autoNumber ? (columnIndex + 1) : columnIndex); - if (columnIndex == -1) { - cell.columnType = "I"; - } else { - cell.columnType = (columnTypes && columnTypes[columnIndex]) ? columnTypes[columnIndex] : "S"; - } - if (cell.columnType != "X") { - cell.onmouseover = function () { - this.saveTitle = this.getAttribute('title'); - this.setAttribute('title', customize.sortTip + " " + ((this.saveTitle != null) && (this.saveTitle != undefined) ? this.saveTitle : '')); - }; - cell.onmouseout = function () { - this.setAttribute('title', this.saveTitle); - }; - cell.onclick = function () { - sortByCell(this, customize.firstDataRowIndex, customize.footingCount); - }; - } else { - cell.columnType = cell.columnType.substring(1); - } -} -function sumColumn(table, index, firstDataRowIndex, columnType) { - var total = 0; - for (var i = firstDataRowIndex; i < table.rows.length; i++) { - var cell = table.rows[i].cells[index]; - var value; - if (cell) { - if (columnType == 'C') { - value = parseFloat(getElementInnerText(cell).replace(/[^\d\.\,\-]*([\d\.\,\-*]*).*/, '$1')) - } else { - value = parseFloat(getElementInnerText(cell)); - } - if (!isNaN(value)) { - total = total + value; - } - } - } - return total; -} -function appendTotalRow(table, columnTypes, firstDataRowIndex) { - var row = document.createElement('tr'); - var table = table.tBodies[0]; - var columnCount = (0 < table.rows.length) ? table.rows[table.rows.length - 1].cells.length : 0; - for (var columnIndex = 0; columnIndex < columnCount; columnIndex++) { - var column = document.createElement('th'); - column.className = 'confluenceTh'; - column.innerHTML = (columnIndex < columnTypes.length && ((columnTypes[columnIndex] == 'I') || (columnTypes[columnIndex] == 'F') || (columnTypes[columnIndex] == 'C'))) ? sumColumn(table, columnIndex, firstDataRowIndex, columnTypes[columnIndex]) : ''; - row.appendChild(column); - } - table.appendChild(row); -} -function handleRow(table, row, rowIndex, customize) { - var columnCount = row.cells.length; - for (var i = 0; i < columnCount; i++) { - if (customize.enableSorting && (rowIndex <= customize.lastClickableRow)) { - enableSortOnCell(row.cells[i], i, table, customize.columnTypes, customize); - } - if ((rowIndex == 0) && (customize.sortColumn != '') && (customize.sortCell == null) && (((i + 1).toString() == customize.sortColumn) || (trimSafe(getElementInnerText(row.cells[i])) == customize.sortColumn) || (trimSafe(row.cells[i].getAttribute('title')) == customize.sortColumn))) { - customize.sortCell = row.cells[i]; - } - if (customize.firstDataRowIndex <= rowIndex) { - if ((customize.columnTypes[i] == "I") || (customize.columnTypes[i] == "F") || (customize.columnTypes[i] == "C")) { - row.cells[i].style.textAlign = "right"; - } - } - if (customize.columnTypes[i] == "H") { - row.cells[i].style.display = "none"; - } - if (customize.enableHeadingAttributes || (customize.firstDataRowIndex <= rowIndex)) { - if (i < customize.attrList.length) { - for (var j = 0; j < customize.attrList[i].length; j++) { - var attr = customize.attrList[i][j].Trim().split("="); - if (1 < attr.length) { - var aName = attr[0].Trim(); - var aValue = attr[1].Trim(); - if ((aName.toLowerCase() == "style") && (2 < aValue.length)) { - if ((aValue.charAt(0) == '"')) { - aValue = aValue.substring(1, aValue.length - 1); - } - row.cells[i].style.cssText = aValue; - } else { - row.cells[i].setAttribute(aName, aValue); - } - } - } - } - } - } - if (customize.autoNumber) { - var column = document.createElement(!customize.autoNumberSort || (rowIndex < customize.firstDataRowIndex) ? 'th' : 'td'); - column.className = (!customize.autoNumberSort || (rowIndex < customize.firstDataRowIndex) ? 'confluenceTh' : 'confluenceTd'); - column.innerHTML = ((rowIndex < customize.firstDataRowIndex) || (customize.totalRowCount - customize.firstDataRowIndex - customize.footingCount < rowIndex) ? '' : customize.dataRowCount++); - column.setAttribute('align', 'right'); - row.autoNumber = !customize.autoNumberSort; - row.insertBefore(column, row.cells[0]); - if (customize.enableSorting && customize.autoNumberSort && (rowIndex <= customize.lastClickableRow)) { - enableSortOnCell(column, -1, table, null, customize); - } - } - if ((customize.highlightColor != "") && (customize.firstDataRowIndex <= rowIndex)) { - row.onmouseover = function () { - this.tableHighLightRowColor = this.bgColor; - this.bgColor = customize.highlightColor; - }; - row.onmouseout = function () { - this.bgColor = this.tableHighLightRowColor; - this.tableHighLightRowColor = null; - }; - } -} -function customizeMacroTable(tableId, columnTypes, firstDataRowIndex, highlightColor, enableSorting, sortTip, sortColumn, sortDescending, autoNumber, autoNumberSort, enableHeadingAttributes, footingCount, autoTotal, iconLocation) { - var customize = new Object; - customize.columnTypes = columnTypes; - customize.firstDataRowIndex = firstDataRowIndex; - customize.highlightColor = highlightColor; - customize.enableSorting = enableSorting; - customize.sortTip = sortTip; - customize.sortColumn = sortColumn; - customize.sortDescending = sortDescending; - customize.autoNumber = autoNumber; - customize.autoNumberSort = autoNumberSort; - customize.enableHeadingAttributes = enableHeadingAttributes; - customize.footingCount = footingCount; - customize.autoTotal = autoTotal; - customize.iconLocation = iconLocation; - var table = (typeof(tableId) == "string") ? document.getElementById(tableId) : null; - if (table) { - if (customize.autoTotal) { - appendTotalRow(table, customize.columnTypes, customize.firstDataRowIndex); - customize.footingCount++; - } - if (customize.iconLocation != "") { - table.sortAttributeAscending = contextPath + customize.iconLocation + "down.gif"; - table.sortAttributeDescending = contextPath + customize.iconLocation + "up.gif"; - table.sortImage = document.createElement("IMG"); - } - customize.lastClickableRow = customize.firstDataRowIndex - 1; - if (customize.lastClickableRow < 0) { - customize.lastClickableRow = 0; - } - customize.sortCell = null; - customize.dataRowCount = 1; - var colAttrs = columnAttributes.split(","); - customize.attrList = Array(colAttrs.length); - for (var i = 0; i < colAttrs.length; i++) { - customize.attrList[i] = colAttrs[i].Trim().split(";;"); - } - var rowIndex = 0; - var headRowCount = (table.tHead == null) ? 0 : table.tHead.rows.length; - var footRowCount = (table.tFoot == null) ? 0 : table.tFoot.rows.length; - var bodyRowCount = table.tBodies[0].rows.length; - customize.totalRowCount = headRowCount + footRowCount + bodyRowCount; - for (var i = 0; i < headRowCount; i++) { - var row = table.tHead.rows[i]; - handleRow(table, row, rowIndex, customize); - rowIndex++; - } - for (var i = 0; i < bodyRowCount; i++) { - var row = table.tBodies[0].rows[i]; - handleRow(table, row, rowIndex, customize); - rowIndex++; - } - for (var i = 0; i < footRowCount; i++) { - var row = table.tFoot.rows[i]; - handleRow(table, row, rowIndex, customize); - rowIndex++; - } - if (customize.sortCell != null) { - customize.sortCell.sortDescending = customize.sortDescending; - sortByCell(customize.sortCell, customize.firstDataRowIndex, customize.footingCount); - } - } - return table; -} - -var columnTypes = ['S']; -var columnAttributes = 'style="white-space:nowrap;",,'; -customizeMacroTable('table-latest', columnTypes, 1, 'lightgoldenrodyellow', true, 'Click to sort', '', false, false, false, true, 0, false, ''); -customizeMacroTable('table-1.2.x', columnTypes, 1, 'lightgoldenrodyellow', true, 'Click to sort', '', false, false, false, true, 0, false, ''); -customizeMacroTable('table-1.1.0', columnTypes, 1, 'lightgoldenrodyellow', true, 'Click to sort', '', false, false, false, true, 0, false, ''); -//--> -</script>
