#* Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. *# #* This version uses .css files for styling use classes in tags like this: You can use multiple class: classes used: sectionTable - format for subsections sectionBody - format for subsections subsectionTable - format for subsections subsectionBody - format for subsections subsectionToc - format used for news items and other places wanting a subsection toc navBar - for navigation bar navBarItem - for navigation bar item at any level navPartHeading - for navigation bar item used as heading with no href part pageBanner - for top page banner topLogos - for top logos on page banner pageFooter - for bottom page footer source - for source-code block displays done with tag smaller - add to make smaller font start the processing *# #document() ## end the processing ## This is where the macro's live ## #macro ( metaauthor $author $email ) #end ## #macro ( source $value)
    $escape.getText($value.getText())
  
#end ## #macro ( subsection $subsection) #if ($subsection.getAttributeValue("id")) #else
#end
##

$subsection.getAttributeValue("name") #if ($subsection.getAttributeValue('title')) – $subsection.getAttributeValue('title') #end

#foreach ( $item in $subsection.getChildren() ) #if ($item.getName().equals("source")) #source ($item) #elseif ($item.getName().equals("insertDownloads")) #insertDownloads ($item) #else $item #end #end
#end ## #macro ( section $section)
#if ($section.getAttributeValue("id")) #else
#end

 $section.getAttributeValue("name")

#foreach ( $item in $section.getChildren() ) #if ($item.getName().equals("source")) #source ($item) #elseif ($item.getName().equals("subsection")) #subsection ($item) #elseif ($item.getName().equals("subsectionToc")) #subsectionToc ($section.getChildren("subsection")) #elseif ($item.getName().equals("insertDownloads")) #insertDownloads ($item) #else $item #end #end

#end ## #macro ( subsectionToc $subsections ) #if ($subsections.get(0).getAttributeValue("title")) #foreach ( $item in $subsections ) #end
$!item.getAttributeValue("date") #if ($item.getAttributeValue("title")) $item.getAttributeValue("title") #else $item.getAttributeValue("name") #end
#else #end #end ## #macro ( projectanchor $name $href) #if (!$href) #elseif ($href.startsWith("http://") || $href.startsWith("https://")) $name #else $name #end #end ## #macro ( navBarParts $items ) #end ## #macro (getApacheImage) #if ($project.getChild("logo")) #set ( $logoString = $project.getChild("logo").getAttributeValue("href") ) #if ( $logoString.startsWith("/") ) $project.getChild( #else $project.getChild( #end #end #end ## #macro (getProjectImage) #if ($project.getChild("projectLogo")) #set ( $logoString = $project.getChild("projectLogo").getAttributeValue("href") ) #if ( $logoString.startsWith("/") ) $project.getChild( #else $project.getChild( #end #end #end ## #macro (getBannerTitle) #if ( $root.getChild("properties").getChild("bannertitle") ) #set ( $pageBanner = $root.getChild("properties").getChild("bannertitle") ) #else #set ( $pageBanner = $root.getChild("properties").getChild("title").getText() ) #end
$pageBanner
#end ## #macro (printMeta $metaElement) #end ## #macro (document) #set ($authors = $root.getChild("properties").getChildren("author")) #foreach ( $au in $authors ) #metaauthor ( $au.getText() $au.getAttributeValue("email") ) #end ## #set ($metas = $root.getChildren("meta")) ## ## Parse meta directives such as ## #foreach ($meta in $metas) #printMeta($meta) #end ## ## Support for tags. #if ($root.getChild("properties").getChild("base")) #set ($url = $root.getChild("properties").getChild("base").getAttributeValue("href")) #end ## $project.getChild("title").getText() - $root.getChild("properties").getChild("title").getText() #set ($scripts = $root.getChild("scripts")) #if ($scripts) #foreach ( $item in $scripts.getChildren() ) $item #end #end
#getProjectImage() #getBannerTitle() #getApacheImage()

##
Search the site
## ## special ACon Logo - leave here for next time ## ## ApacheCon US 2005 ## ## ## #navBarParts($project.getChild("menus").getChildren("item")) #set ($allSections = $root.getChild("body").getChildren("section")) #foreach ( $section in $allSections ) #section ($section) #end

#end ## ## support for download entries ## Put release version applicable for whole table into downloads element version attribute ## version="2.2.2-incubating" will be inserted in various places ## ## one or more elements - one per item (will have releasenotes, binaries, source) ## name attribute is 1st column - plain English ## subdirectory - is dir under which things (except release notes?) are found ## is subdir of binaries and source ## ## txt, html ## if not txt or html, ## the kind value is the title to display, and the filename has to include the file type. ## if file not store at the top, include the path part after ...dist/uima ## ## as above (no file type). ## file types indicated using txt, html zip tgz etc. ## if platform dependent, use ## ## #macro (insertDownloads $insertVersionInfo) #set ($version = $insertVersionInfo.getAttributeValue("version")) ## #set ($allDownloads = $project.getChildren("downloads")) #foreach ($potentialDownloads in $allDownloads) ## #if ($potentialDownloads.getAttributeValue("version").equals($version)) #insertDownload2 ($potentialDownloads) #end #end #end ## #macro (insertDownload2 $downloads) #set ( $rn = "https://svn.apache.org/repos/asf/uima/site/archive/docs/d") #if ($downloads.getAttributeValue("withreleasedate")) #end ## #foreach ( $download in $downloads.getChildren("download")) #if ($download.getAttributeValue("archived")) #set ( $drmirror = "https://archive.apache.org/dist/uima") #set ( $dr = "https://archive.apache.org/dist/uima") #else #set ( $drmirror = "[preferred]/uima") #set ( $dr = "https://www.apache.org/dist/uima") #end #set ($subdirectory = $download.getAttributeValue("subdirectory")) ## #set ($releasenotes = $download.getChild("releasenotes")) #set ($releasenotestitle = 'no title') #if ($releasenotes.getAttributeValue("title")) #set ($releasenotestitle = $releasenotes.getAttributeValue("title")) #end ## #else $download.getAttributeValue("name") #end ## #set ($source = $download.getChild("source")) #if ($downloads.getAttributeValue("withreleasedate")) #end #end ##
Artifact Release
Notes
Binary SourceRelease Date

#if ($releasenotes.getChild("f")) $download.getAttributeValue("name")

#if ($releasenotes.getChild("f")) #foreach ($suffix in $releasenotes.getChildren("f")) #end #else #if ($releasenotestitle.equals('no title')) #set ($releasenotestitle = "Release Notes") #end $releasenotestitle #end #foreach ($binary in $download.getChildren("binary")) #if ($downloads.getAttributeValue("incubator")) #suffixes ('binaries' $binary $subdirectory) #else #suffixes ('' $binary $subdirectory) #end #end #if ($source.getChild("f")) #if ($downloads.getAttributeValue("incubator")) #suffixes ('source' $source $subdirectory) #else #suffixes ('' $source $subdirectory) #end #else $source #end
$download.getAttributeValue("releasedate")
#end #macro ( suffixes $dir $item $subdirectory) #foreach ($suffix in $item.getChildren("f")) #set ($ft = $suffix.getText()) #set ($filename = $item.getAttributeValue("filename")) #set ($platform = $suffix.getAttributeValue("platform")) #if ($platform.endsWith("64-bit")) #set ($filenameType = "${filename}64.$ft") #else #set ($filenameType = "${filename}.$ft") #end ## removed per change in apache release policy 4/2018 schor ## removed per change in apache release policy 8/2018 schor #if ($suffix.getAttributeValue("platform")) #end #end
$ft [asc][md5][sha1][sha512]$suffix.getAttributeValue("platform")
#end