From version < 458.1 >
edited by Vincent Massol
on 2015/03/16
To version < 459.1 >
edited by Vincent Massol
on 2015/03/16
< >
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -23,49 +23,19 @@
23 23  
24 24  == JavaDoc ==
25 25  
26 -XWiki is made of various extensions/modules and each module offers API for both developers coding in Java and for Scripts written in wiki pages. In the future our goal is to have Javadoc links directly from each extension page located in the [[Extensions Wiki>>extensions:Main.WebHome]]. Right now we're listing below the Javadocs for all modules.
26 +XWiki is made of various extensions/modules and each module offers API for both developers coding in Java and for Scripts written in wiki pages. In the future our goal is to have Javadoc links directly from each extension page located in the [[Extensions Wiki>>extensions:Main.WebHome]].
27 27  
28 28  {{velocity}}
29 -#if ("$!request.versionId" != '')
30 - #set ($versionId = $request.versionId)
31 - #set ($versionName = $request.versionName)
32 -#else
33 - #set ($versionId = $versionStable)
34 - #set ($versionName = "stable")
29 +Right now we're providing all Javadocs for all modules:
30 +* [[Javadoc for XWiki ${versionStable} (stable)>>Javadoc||queryString="versionId=$versionStable&versionName=stable"]]
31 +#if ($versionDev)
32 + * [[Javadoc for XWiki ${versionDev} (dev)>>Javadoc||queryString="versionId=$versionDev&versionName=dev"]]
35 35  #end
36 -#set ($discard = $xcontext.put('javadocVersion', $versionId))
37 -
38 -Javadoc for version $versionId ($versionName) ([[stable: $versionStable>>||anchor="HJavaDoc" queryString="versionId=$versionStable&versionName=stable"]]#if ($versionDev), [[dev: $versionDev>>||anchor="HJavaDoc" queryString="versionId=$versionDev&versionName=dev"]]#{end}#if ($versionOldStable), [[super stable: $versionOldStable>>||anchor="HJavaDoc" queryString="versionId=$versionOldStable&versionName='super stable'"]]#{end}):
34 +#if ($versionOldStable)
35 + * [[Javadoc for XWiki ${versionOldStable} (super stable)>>Javadoc||queryString="versionId=$versionOldStable&versionName='super stable'"]]
36 +#end
39 39  {{/velocity}}
40 40  
41 -{{groovy}}
42 -import groovy.xml.*
43 -import org.apache.commons.lang3.*
44 -
45 -def offset = 0
46 -def count = 200
47 -def shouldContinue = true
48 -
49 -while (shouldContinue) {
50 - def url = "http://nexus.xwiki.org/nexus/service/local/lucene/search?g=org.xwiki.*&v=${xcontext.javadocVersion}&p=jar&c=javadoc&from=${offset}&count=${count}".toURL().text
51 - def root = new XmlSlurper().parseText(url)
52 -
53 - offset += count
54 - def total = Integer.parseInt(root.totalCount.text())
55 - shouldContinue = total > offset ? true : false
56 -
57 - root.data.artifact.each { artifact ->
58 - // Extract the last part of the group id and consider it's the repo short name
59 - def groupId = artifact.groupId.text()
60 - def repo = StringUtils.substringAfterLast(groupId, ".")
61 - def artifactId = artifact.artifactId
62 - def version = artifact.version
63 - def javadocURL = "http://nexus.xwiki.org/nexus/service/local/repositories/releases/archive/org/xwiki/${repo}/${artifactId}/${version}/${artifactId}-${version}-javadoc.jar/!/index.html"
64 - println "* [[${artifactId}>>url:${javadocURL}]]"
65 - }
66 -}
67 -{{/groovy}}
68 -
69 69  The [[full Javadoc>>http://maven.xwiki.org/site/docs/]] is also available ({{info}}but only for old versions, we need to fix this{{/info}}).
70 70  
71 71  Older Javadocs of XWiki can be found in our [[Maven Release repository>>http://maven.xwiki.org/releases/]]. For example for XWiki Platform Core Javadocs, check the files suffixed by ##javadoc## for the version you wish under [[this directory>>http://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-oldcore/]].

Get Connected