ai4r 1.2 → 1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (139) hide show
  1. data/README.rdoc +12 -25
  2. data/examples/decision_trees/id3_example.rb +6 -9
  3. data/examples/decision_trees/results.txt +2 -0
  4. data/examples/genetic_algorithm/genetic_algorithm_example.rb +11 -13
  5. data/examples/neural_network/xor_example.rb +25 -0
  6. data/lib/ai4r.rb +10 -0
  7. data/lib/ai4r/classifiers/classifier.rb +46 -0
  8. data/lib/ai4r/classifiers/id3.rb +27 -58
  9. data/lib/ai4r/classifiers/one_r.rb +19 -58
  10. data/lib/ai4r/classifiers/prism.rb +21 -57
  11. data/lib/ai4r/classifiers/zero_r.rb +16 -48
  12. data/lib/ai4r/clusterers/bisecting_k_means.rb +115 -0
  13. data/lib/ai4r/clusterers/clusterer.rb +55 -0
  14. data/lib/ai4r/clusterers/k_means.rb +164 -0
  15. data/lib/ai4r/data/data_set.rb +250 -0
  16. data/lib/ai4r/genetic_algorithm/genetic_algorithm.rb +19 -19
  17. data/lib/ai4r/neural_network/backpropagation.rb +23 -24
  18. data/site/build/site/en/broken-links.xml +2 -0
  19. data/site/build/site/en/downloads.html +200 -0
  20. data/site/build/site/en/downloads.pdf +151 -0
  21. data/site/build/site/en/forum.html +197 -0
  22. data/site/build/site/en/forum.pdf +151 -0
  23. data/site/build/site/en/geneticAlgorithms.html +591 -0
  24. data/site/build/site/en/geneticAlgorithms.pdf +934 -0
  25. data/site/build/site/en/images/ai4r-logo.png +0 -0
  26. data/site/build/site/en/images/built-with-forrest-button.png +0 -0
  27. data/site/build/site/en/images/c.png +0 -0
  28. data/site/build/site/en/images/c_wbn.png +0 -0
  29. data/site/build/site/en/images/c_wn.png +0 -0
  30. data/site/build/site/en/images/ero.gif +0 -0
  31. data/site/build/site/en/images/europe2.png +0 -0
  32. data/site/build/site/en/images/europe3.png +0 -0
  33. data/site/build/site/en/images/fitness.png +0 -0
  34. data/site/build/site/en/images/genetic_algorithms_example.png +0 -0
  35. data/site/build/site/en/images/instruction_arrow.png +0 -0
  36. data/site/build/site/en/images/jadeferret.png +0 -0
  37. data/site/build/site/en/images/my_email.png +0 -0
  38. data/site/build/site/en/images/neural_network_example.png +0 -0
  39. data/site/build/site/en/images/rubyforge.png +0 -0
  40. data/site/build/site/en/images/s.png +0 -0
  41. data/site/build/site/en/images/s_wbn.png +0 -0
  42. data/site/build/site/en/images/s_wn.png +0 -0
  43. data/site/build/site/en/images/sigmoid.png +0 -0
  44. data/site/build/site/en/images/t.png +0 -0
  45. data/site/build/site/en/images/t_wbn.png +0 -0
  46. data/site/build/site/en/images/t_wn.png +0 -0
  47. data/site/build/site/en/index.html +336 -0
  48. data/site/build/site/en/index.pdf +508 -0
  49. data/site/build/site/en/linkmap.html +263 -0
  50. data/site/build/site/en/linkmap.pdf +94 -0
  51. data/site/build/site/en/locationmap.xml +72 -0
  52. data/site/build/site/en/machineLearning.html +339 -0
  53. data/site/build/site/en/machineLearning.pdf +337 -0
  54. data/site/build/site/en/neuralNetworks.html +484 -0
  55. data/site/build/site/en/neuralNetworks.pdf +604 -0
  56. data/site/build/site/en/skin/CommonMessages_de.xml +23 -0
  57. data/site/build/site/en/skin/CommonMessages_en_US.xml +23 -0
  58. data/site/build/site/en/skin/CommonMessages_es.xml +23 -0
  59. data/site/build/site/en/skin/CommonMessages_fr.xml +23 -0
  60. data/site/build/site/en/skin/basic.css +166 -0
  61. data/site/build/site/en/skin/breadcrumbs-optimized.js +90 -0
  62. data/site/build/site/en/skin/breadcrumbs.js +237 -0
  63. data/site/build/site/en/skin/fontsize.js +166 -0
  64. data/site/build/site/en/skin/getBlank.js +40 -0
  65. data/site/build/site/en/skin/getMenu.js +45 -0
  66. data/site/build/site/en/skin/images/README.txt +1 -0
  67. data/site/build/site/en/skin/images/add.jpg +0 -0
  68. data/site/build/site/en/skin/images/built-with-forrest-button.png +0 -0
  69. data/site/build/site/en/skin/images/chapter.gif +0 -0
  70. data/site/build/site/en/skin/images/chapter_open.gif +0 -0
  71. data/site/build/site/en/skin/images/current.gif +0 -0
  72. data/site/build/site/en/skin/images/error.png +0 -0
  73. data/site/build/site/en/skin/images/external-link.gif +0 -0
  74. data/site/build/site/en/skin/images/fix.jpg +0 -0
  75. data/site/build/site/en/skin/images/forrest-credit-logo.png +0 -0
  76. data/site/build/site/en/skin/images/hack.jpg +0 -0
  77. data/site/build/site/en/skin/images/header_white_line.gif +0 -0
  78. data/site/build/site/en/skin/images/info.png +0 -0
  79. data/site/build/site/en/skin/images/instruction_arrow.png +0 -0
  80. data/site/build/site/en/skin/images/label.gif +0 -0
  81. data/site/build/site/en/skin/images/page.gif +0 -0
  82. data/site/build/site/en/skin/images/pdfdoc.gif +0 -0
  83. data/site/build/site/en/skin/images/poddoc.png +0 -0
  84. data/site/build/site/en/skin/images/printer.gif +0 -0
  85. data/site/build/site/en/skin/images/rc-b-l-15-1body-2menu-3menu.png +0 -0
  86. data/site/build/site/en/skin/images/rc-b-r-15-1body-2menu-3menu.png +0 -0
  87. data/site/build/site/en/skin/images/rc-b-r-5-1header-2tab-selected-3tab-selected.png +0 -0
  88. data/site/build/site/en/skin/images/rc-t-l-5-1header-2searchbox-3searchbox.png +0 -0
  89. data/site/build/site/en/skin/images/rc-t-l-5-1header-2tab-selected-3tab-selected.png +0 -0
  90. data/site/build/site/en/skin/images/rc-t-l-5-1header-2tab-unselected-3tab-unselected.png +0 -0
  91. data/site/build/site/en/skin/images/rc-t-r-15-1body-2menu-3menu.png +0 -0
  92. data/site/build/site/en/skin/images/rc-t-r-5-1header-2searchbox-3searchbox.png +0 -0
  93. data/site/build/site/en/skin/images/rc-t-r-5-1header-2tab-selected-3tab-selected.png +0 -0
  94. data/site/build/site/en/skin/images/rc-t-r-5-1header-2tab-unselected-3tab-unselected.png +0 -0
  95. data/site/build/site/en/skin/images/remove.jpg +0 -0
  96. data/site/build/site/en/skin/images/rss.png +0 -0
  97. data/site/build/site/en/skin/images/spacer.gif +0 -0
  98. data/site/build/site/en/skin/images/success.png +0 -0
  99. data/site/build/site/en/skin/images/txtdoc.png +0 -0
  100. data/site/build/site/en/skin/images/update.jpg +0 -0
  101. data/site/build/site/en/skin/images/valid-html401.png +0 -0
  102. data/site/build/site/en/skin/images/vcss.png +0 -0
  103. data/site/build/site/en/skin/images/warning.png +0 -0
  104. data/site/build/site/en/skin/images/xmldoc.gif +0 -0
  105. data/site/build/site/en/skin/menu.js +48 -0
  106. data/site/build/site/en/skin/note.txt +50 -0
  107. data/site/build/site/en/skin/print.css +54 -0
  108. data/site/build/site/en/skin/profile.css +163 -0
  109. data/site/build/site/en/skin/prototype.js +1257 -0
  110. data/site/build/site/en/skin/screen.css +587 -0
  111. data/site/build/site/en/svn.html +252 -0
  112. data/site/build/site/en/svn.pdf +306 -0
  113. data/site/build/site/en/wholesite.pdf +1915 -0
  114. data/site/build/tmp/brokenlinks.xml +2 -0
  115. data/site/build/tmp/cocoon-work/cache-dir/cocoon-ehcache-1.data +0 -0
  116. data/site/build/tmp/cocoon-work/cache-dir/cocoon-ehcache-1.index +0 -0
  117. data/site/build/tmp/locationmap.xml +14 -14
  118. data/site/build/tmp/output.xmap +23 -23
  119. data/site/build/tmp/pluginlist2fetchbuild.xml +144 -144
  120. data/site/build/tmp/projfilters.properties +41 -41
  121. data/site/build/webapp/WEB-INF/logs/core.log +593 -679
  122. data/site/build/webapp/WEB-INF/logs/error.log +362 -279
  123. data/site/build/webapp/WEB-INF/logs/sitemap.log +368 -1015
  124. data/site/src/documentation/content/xdocs/index.xml +18 -10
  125. data/site/src/documentation/content/xdocs/machineLearning.xml +4 -3
  126. data/site/src/documentation/content/xdocs/site.xml +2 -1
  127. data/site/src/documentation/resources/images/sigmoid.png +0 -0
  128. data/test/classifiers/id3_test.rb +45 -44
  129. data/test/classifiers/one_r_test.rb +19 -17
  130. data/test/classifiers/prism_test.rb +22 -20
  131. data/test/classifiers/zero_r_test.rb +15 -12
  132. data/test/clusterers/bisecting_k_means_test.rb +59 -0
  133. data/test/clusterers/k_means_test.rb +93 -0
  134. data/test/data/data_set_test.rb +92 -0
  135. metadata +252 -128
  136. data/lib/ai4r/classifiers/classifier_helper.rb +0 -54
  137. data/site/src/documentation/content/xdocs/forum.html +0 -9
  138. data/site/src/documentation/resources/images/Thumbs.db +0 -0
  139. data/site/src/documentation/resources/images/sub-dir/Thumbs.db +0 -0
@@ -0,0 +1,2 @@
1
+ <broken-links>
2
+ </broken-links>
@@ -1,4 +1,4 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
2
  <!--
3
3
  Licensed to the Apache Software Foundation (ASF) under one or more
4
4
  contributor license agreements. See the NOTICE file distributed with
@@ -14,16 +14,16 @@
14
14
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
15
  See the License for the specific language governing permissions and
16
16
  limitations under the License.
17
- -->
18
- <locationmap xmlns="http://apache.org/forrest/locationmap/1.0" xmlns:lm="http://apache.org/forrest/locationmap/1.0">
19
- <components>
20
- <selectors default="exists">
21
- <selector name="exists" logger="sitemap.selector.exists" src="org.apache.forrest.sourceexists.SourceExistsSelector"/>
22
- </selectors>
23
- </components>
24
- <locator>
25
- <select>
26
- <mount src="{forrest:forrest.plugins}/org.apache.forrest.plugin.output.pdf/locationmap.xml"/>
27
- </select>
28
- </locator>
29
- </locationmap>
17
+ -->
18
+ <locationmap xmlns="http://apache.org/forrest/locationmap/1.0" xmlns:lm="http://apache.org/forrest/locationmap/1.0">
19
+ <components>
20
+ <selectors default="exists">
21
+ <selector name="exists" logger="sitemap.selector.exists" src="org.apache.forrest.sourceexists.SourceExistsSelector"/>
22
+ </selectors>
23
+ </components>
24
+ <locator>
25
+ <select>
26
+ <mount src="{forrest:forrest.plugins}/org.apache.forrest.plugin.output.pdf/locationmap.xml"/>
27
+ </select>
28
+ </locator>
29
+ </locationmap>
@@ -1,4 +1,4 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
2
  <!--
3
3
  Licensed to the Apache Software Foundation (ASF) under one or more
4
4
  contributor license agreements. See the NOTICE file distributed with
@@ -14,25 +14,25 @@
14
14
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
15
  See the License for the specific language governing permissions and
16
16
  limitations under the License.
17
- -->
18
- <!-- ============================================================ -->
19
- <!-- Plugin Sitemap -->
20
- <!-- -->
21
- <!-- This sitemap includes all enabled plugins in the generation -->
22
- <!-- process. It is mounted from the main Forrest sitemap after -->
23
- <!-- any project specific sitemap but before the default Forrest -->
24
- <!-- matchers. This enables plugins to override or extend default -->
25
- <!-- Forrest behaviour whilst individual projects can override -->
26
- <!-- or extend the plugins behaviour. -->
27
- <!-- ============================================================ -->
28
- <map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
29
- <map:pipelines>
30
- <map:pipeline>
31
- <map:select type="exists">
32
- <map:when test="{forrest:forrest.plugins}/org.apache.forrest.plugin.output.pdf/output.xmap">
33
- <map:mount uri-prefix="" src="{forrest:forrest.plugins}/org.apache.forrest.plugin.output.pdf/output.xmap" check-reload="yes" pass-through="true"/>
34
- </map:when>
35
- </map:select>
36
- </map:pipeline>
37
- </map:pipelines>
38
- </map:sitemap>
17
+ -->
18
+ <!-- ============================================================ -->
19
+ <!-- Plugin Sitemap -->
20
+ <!-- -->
21
+ <!-- This sitemap includes all enabled plugins in the generation -->
22
+ <!-- process. It is mounted from the main Forrest sitemap after -->
23
+ <!-- any project specific sitemap but before the default Forrest -->
24
+ <!-- matchers. This enables plugins to override or extend default -->
25
+ <!-- Forrest behaviour whilst individual projects can override -->
26
+ <!-- or extend the plugins behaviour. -->
27
+ <!-- ============================================================ -->
28
+ <map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
29
+ <map:pipelines>
30
+ <map:pipeline>
31
+ <map:select type="exists">
32
+ <map:when test="{forrest:forrest.plugins}/org.apache.forrest.plugin.output.pdf/output.xmap">
33
+ <map:mount uri-prefix="" src="{forrest:forrest.plugins}/org.apache.forrest.plugin.output.pdf/output.xmap" check-reload="yes" pass-through="true"/>
34
+ </map:when>
35
+ </map:select>
36
+ </map:pipeline>
37
+ </map:pipelines>
38
+ </map:sitemap>
@@ -1,144 +1,144 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project default="fetchplugin">
3
- <target name="fetchplugin" depends="fetch-local-unversioned-plugin, fetch-remote-unversioned-plugin-version-forrest,fetch-remote-unversioned-plugin-unversion-forrest, final-check"/>
4
- <target name="fetch-local-versioned-plugin">
5
- <antcallback return="plugin-found" target="get-local">
6
- <param name="local-plugin-version" value="-"/>
7
- <param name="local-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
8
- </antcallback>
9
- </target>
10
- <target unless="plugin-found" name="fetch-remote-versioned-plugin-version-forrest">
11
- <antcallback return="plugin-found,desired.plugin.zip.present" target="download">
12
- <param name="download-plugin-version" value="-"/>
13
- <param name="download-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
14
- <param name="download-forrest-version" value="0.8/"/>
15
- </antcallback>
16
- </target>
17
- <target unless="plugin-found" name="fetch-local-unversioned-plugin">
18
- <antcallback return="plugin-found" target="get-local">
19
- <param value="" name="local-plugin-version"/>
20
- <param name="local-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
21
- </antcallback>
22
- </target>
23
- <target unless="plugin-found" name="fetch-remote-unversioned-plugin-version-forrest">
24
- <antcallback return="plugin-found,desired.plugin.zip.present" target="download">
25
- <param value="" name="download-plugin-version"/>
26
- <param name="download-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
27
- <param name="download-forrest-version" value="0.8/"/>
28
- </antcallback>
29
- </target>
30
- <target unless="plugin-found" name="fetch-remote-unversioned-plugin-unversion-forrest">
31
- <antcallback return="plugin-found,desired.plugin.zip.present" target="download">
32
- <param value="" name="download-plugin-version"/>
33
- <param name="download-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
34
- <param value="" name="download-forrest-version"/>
35
- </antcallback>
36
- </target>
37
- <target name="get-local">
38
- <echo>Trying to locally get ${local-plugin-name}${local-plugin-version}</echo>
39
- <trycatch property="plugin-found">
40
- <try>
41
- <for param="plugin-src-dir" list="C:\Development\apache-forrest-0.8/plugins,C:\Development\apache-forrest-0.8/whiteboard/plugins">
42
- <sequential>
43
- <echo>Looking in local @{plugin-src-dir}</echo>
44
- <if>
45
- <available type="dir" property="plugin.src.present" file="@{plugin-src-dir}/${local-plugin-name}${local-plugin-version}"/>
46
- <then>
47
- <echo message="Found !"/>
48
- <ant target="local-deploy" antfile="@{plugin-src-dir}/${local-plugin-name}${local-plugin-version}/build.xml" dir="@{plugin-src-dir}/${local-plugin-name}${local-plugin-version}">
49
- <property value="true" name="no.echo.init"/>
50
- </ant>
51
- <fail/>
52
- </then>
53
- </if>
54
- </sequential>
55
- </for>
56
- </try>
57
- <catch>
58
- <echo>Plugin ${local-plugin-name}${local-plugin-version} deployed ! Ready to configure</echo>
59
- </catch>
60
- </trycatch>
61
- </target>
62
- <target depends="keep-original-zip,get-from-remote-site,is-downloaded,remove-original-zip" name="download"/>
63
- <target if="original.zip.exists" depends="available-original-zip" name="keep-original-zip">
64
- <copy preservelastmodified="true" file="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip" tofile="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip.orig"/>
65
- </target>
66
- <target name="available-original-zip">
67
- <available property="original.zip.exists" file="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip"/>
68
- </target>
69
- <target name="get-from-remote-site">
70
- <echo>Tying to download ${download-plugin-name}${download-plugin-version} from the distribution site ...</echo>
71
- <if>
72
- <not>
73
- <equals arg2="" arg1="${download.forrest.version}"/>
74
- </not>
75
- <then>
76
- <echo>Using Forrest version : ${download-forrest-version}</echo>
77
- </then>
78
- </if>
79
- <get ignoreerrors="true" usetimestamp="true" verbose="true" src="http://forrest.apache.org/plugins//${download-forrest-version}${download-plugin-name}${download-plugin-version}.zip" dest="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip"/>
80
- <available property="desired.plugin.zip.present" file="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip"/>
81
- <condition property="plugin-found">
82
- <and>
83
- <isset property="desired.plugin.zip.present"/>
84
- <not>
85
- <isset property="original.zip.exists"/>
86
- </not>
87
- </and>
88
- </condition>
89
- </target>
90
- <target if="original.zip.exists" name="is-downloaded">
91
- <uptodate property="no-difference-found" srcfile="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip" targetfile="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip.orig"/>
92
- <if>
93
- <not>
94
- <isset property="no-difference-found"/>
95
- </not>
96
- <then>
97
- <property value="true" name="plugin-found"/>
98
- </then>
99
- </if>
100
- </target>
101
- <target if="original.zip.exists" name="remove-original-zip">
102
- <delete file="C:\Development\apache-forrest-0.8\build\plugins/${download-plugin-name}.zip.orig"/>
103
- </target>
104
- <target depends="has-been-downloaded,downloaded-message,uptodate-message,not-found-message" name="final-check"/>
105
- <target if="desired.plugin.zip.present" name="has-been-downloaded">
106
- <condition property="up-to-date">
107
- <not>
108
- <isset property="plugin-found"/>
109
- </not>
110
- </condition>
111
- <condition property="downloaded">
112
- <isset property="plugin-found"/>
113
- </condition>
114
- </target>
115
- <target if="downloaded" name="downloaded-message">
116
- <echo>Plugin org.apache.forrest.plugin.output.pdf downloaded ! Ready to install</echo>
117
- </target>
118
- <target if="up-to-date" name="uptodate-message">
119
- <echo>Plugin org.apache.forrest.plugin.output.pdf was up-to-date ! Ready to configure</echo>
120
- <property value="true" name="plugin-found"/>
121
- </target>
122
- <target unless="desired.plugin.zip.present" name="not-found-message">
123
- <fail>
124
- Unable to download the
125
- "org.apache.forrest.plugin.output.pdf" plugin
126
-
127
- or an equivalent unversioned plugin
128
- from http://forrest.apache.org/plugins/
129
- There are a number of possible causes for this:
130
-
131
- One possible problem is that you do not have write access to
132
- FORREST_HOME, in which case ask your system admin to install the
133
- required Forrest plugin as described below.
134
-
135
- A further possibility is that Forrest may be unable to connect to
136
- the plugin distribution server. Again the solution is to manually
137
- install the plugin.
138
-
139
- To manually install a plugin, download the plugin zip file from
140
- http://forrest.apache.org/plugins/ and
141
- extract it into
142
- C:\Development\apache-forrest-0.8\build\plugins/org.apache.forrest.plugin.output.pdf</fail>
143
- </target>
144
- </project>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project default="fetchplugin">
3
+ <target name="fetchplugin" depends="fetch-local-unversioned-plugin, fetch-remote-unversioned-plugin-version-forrest,fetch-remote-unversioned-plugin-unversion-forrest, final-check"/>
4
+ <target name="fetch-local-versioned-plugin">
5
+ <antcallback return="plugin-found" target="get-local">
6
+ <param name="local-plugin-version" value="-"/>
7
+ <param name="local-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
8
+ </antcallback>
9
+ </target>
10
+ <target unless="plugin-found" name="fetch-remote-versioned-plugin-version-forrest">
11
+ <antcallback return="plugin-found,desired.plugin.zip.present" target="download">
12
+ <param name="download-plugin-version" value="-"/>
13
+ <param name="download-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
14
+ <param name="download-forrest-version" value="0.8/"/>
15
+ </antcallback>
16
+ </target>
17
+ <target unless="plugin-found" name="fetch-local-unversioned-plugin">
18
+ <antcallback return="plugin-found" target="get-local">
19
+ <param value="" name="local-plugin-version"/>
20
+ <param name="local-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
21
+ </antcallback>
22
+ </target>
23
+ <target unless="plugin-found" name="fetch-remote-unversioned-plugin-version-forrest">
24
+ <antcallback return="plugin-found,desired.plugin.zip.present" target="download">
25
+ <param value="" name="download-plugin-version"/>
26
+ <param name="download-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
27
+ <param name="download-forrest-version" value="0.8/"/>
28
+ </antcallback>
29
+ </target>
30
+ <target unless="plugin-found" name="fetch-remote-unversioned-plugin-unversion-forrest">
31
+ <antcallback return="plugin-found,desired.plugin.zip.present" target="download">
32
+ <param value="" name="download-plugin-version"/>
33
+ <param name="download-plugin-name" value="org.apache.forrest.plugin.output.pdf"/>
34
+ <param value="" name="download-forrest-version"/>
35
+ </antcallback>
36
+ </target>
37
+ <target name="get-local">
38
+ <echo>Trying to locally get ${local-plugin-name}${local-plugin-version}</echo>
39
+ <trycatch property="plugin-found">
40
+ <try>
41
+ <for param="plugin-src-dir" list="/usr/local/forrest/plugins,/usr/local/forrest/whiteboard/plugins">
42
+ <sequential>
43
+ <echo>Looking in local @{plugin-src-dir}</echo>
44
+ <if>
45
+ <available type="dir" property="plugin.src.present" file="@{plugin-src-dir}/${local-plugin-name}${local-plugin-version}"/>
46
+ <then>
47
+ <echo message="Found !"/>
48
+ <ant target="local-deploy" antfile="@{plugin-src-dir}/${local-plugin-name}${local-plugin-version}/build.xml" dir="@{plugin-src-dir}/${local-plugin-name}${local-plugin-version}">
49
+ <property value="true" name="no.echo.init"/>
50
+ </ant>
51
+ <fail/>
52
+ </then>
53
+ </if>
54
+ </sequential>
55
+ </for>
56
+ </try>
57
+ <catch>
58
+ <echo>Plugin ${local-plugin-name}${local-plugin-version} deployed ! Ready to configure</echo>
59
+ </catch>
60
+ </trycatch>
61
+ </target>
62
+ <target depends="keep-original-zip,get-from-remote-site,is-downloaded,remove-original-zip" name="download"/>
63
+ <target if="original.zip.exists" depends="available-original-zip" name="keep-original-zip">
64
+ <copy preservelastmodified="true" file="/usr/local/forrest/build/plugins/${download-plugin-name}.zip" tofile="/usr/local/forrest/build/plugins/${download-plugin-name}.zip.orig"/>
65
+ </target>
66
+ <target name="available-original-zip">
67
+ <available property="original.zip.exists" file="/usr/local/forrest/build/plugins/${download-plugin-name}.zip"/>
68
+ </target>
69
+ <target name="get-from-remote-site">
70
+ <echo>Tying to download ${download-plugin-name}${download-plugin-version} from the distribution site ...</echo>
71
+ <if>
72
+ <not>
73
+ <equals arg2="" arg1="${download.forrest.version}"/>
74
+ </not>
75
+ <then>
76
+ <echo>Using Forrest version : ${download-forrest-version}</echo>
77
+ </then>
78
+ </if>
79
+ <get ignoreerrors="true" usetimestamp="true" verbose="true" src="http://forrest.apache.org/plugins//${download-forrest-version}${download-plugin-name}${download-plugin-version}.zip" dest="/usr/local/forrest/build/plugins/${download-plugin-name}.zip"/>
80
+ <available property="desired.plugin.zip.present" file="/usr/local/forrest/build/plugins/${download-plugin-name}.zip"/>
81
+ <condition property="plugin-found">
82
+ <and>
83
+ <isset property="desired.plugin.zip.present"/>
84
+ <not>
85
+ <isset property="original.zip.exists"/>
86
+ </not>
87
+ </and>
88
+ </condition>
89
+ </target>
90
+ <target if="original.zip.exists" name="is-downloaded">
91
+ <uptodate property="no-difference-found" srcfile="/usr/local/forrest/build/plugins/${download-plugin-name}.zip" targetfile="/usr/local/forrest/build/plugins/${download-plugin-name}.zip.orig"/>
92
+ <if>
93
+ <not>
94
+ <isset property="no-difference-found"/>
95
+ </not>
96
+ <then>
97
+ <property value="true" name="plugin-found"/>
98
+ </then>
99
+ </if>
100
+ </target>
101
+ <target if="original.zip.exists" name="remove-original-zip">
102
+ <delete file="/usr/local/forrest/build/plugins/${download-plugin-name}.zip.orig"/>
103
+ </target>
104
+ <target depends="has-been-downloaded,downloaded-message,uptodate-message,not-found-message" name="final-check"/>
105
+ <target if="desired.plugin.zip.present" name="has-been-downloaded">
106
+ <condition property="up-to-date">
107
+ <not>
108
+ <isset property="plugin-found"/>
109
+ </not>
110
+ </condition>
111
+ <condition property="downloaded">
112
+ <isset property="plugin-found"/>
113
+ </condition>
114
+ </target>
115
+ <target if="downloaded" name="downloaded-message">
116
+ <echo>Plugin org.apache.forrest.plugin.output.pdf downloaded ! Ready to install</echo>
117
+ </target>
118
+ <target if="up-to-date" name="uptodate-message">
119
+ <echo>Plugin org.apache.forrest.plugin.output.pdf was up-to-date ! Ready to configure</echo>
120
+ <property value="true" name="plugin-found"/>
121
+ </target>
122
+ <target unless="desired.plugin.zip.present" name="not-found-message">
123
+ <fail>
124
+ Unable to download the
125
+ "org.apache.forrest.plugin.output.pdf" plugin
126
+
127
+ or an equivalent unversioned plugin
128
+ from http://forrest.apache.org/plugins/
129
+ There are a number of possible causes for this:
130
+
131
+ One possible problem is that you do not have write access to
132
+ FORREST_HOME, in which case ask your system admin to install the
133
+ required Forrest plugin as described below.
134
+
135
+ A further possibility is that Forrest may be unable to connect to
136
+ the plugin distribution server. Again the solution is to manually
137
+ install the plugin.
138
+
139
+ To manually install a plugin, download the plugin zip file from
140
+ http://forrest.apache.org/plugins/ and
141
+ extract it into
142
+ /usr/local/forrest/build/plugins/org.apache.forrest.plugin.output.pdf</fail>
143
+ </target>
144
+ </project>
@@ -1,41 +1,41 @@
1
- #Ant properties
2
- #Wed Feb 11 16:59:20 GMT 2009
3
- project.sitemap=src/documentation/sitemap.xmap
4
- project.war=C\:\\Development\\workspace\\ai4r\\site\\build\\my-project.war
5
- project.name=my-project
6
- project.brokenlinkfile=C\:\\Development\\workspace\\ai4r\\site\\build\\tmp\\brokenlinks.xml
7
- project.stylesheets-dir=src/documentation/resources/stylesheets
8
- project.webapp=C\:\\Development\\workspace\\ai4r\\site\\build\\webapp
9
- project.skinconf=src/documentation/skinconf.xml
10
- project.debuglevel=ERROR
11
- project.skin=pelt
12
- project.configfile=C\:\\Development\\apache-forrest-0.8\\main\\webapp/WEB-INF/cli.xconf
13
- project.images-dir=src/documentation/resources/images
14
- project.conf-dir=src/documentation/conf
15
- project.temp-dir=C\:\\Development\\workspace\\ai4r\\site/build/tmp
16
- project.translations-dir=src/documentation/translations
17
- project.menu-scheme=tab_attributes
18
- project.lib-dir=src/documentation/lib
19
- project.build-dir=C\:\\Development\\workspace\\ai4r\\site/build
20
- project.classes-dir=src/documentation/classes
21
- project.resources-dir=src/documentation/resources
22
- project.grammars-dir=src/documentation/resources/grammars
23
- project.start-uri=linkmap.html
24
- project.sitemap-dir=src/documentation
25
- project.required.plugins.src=C\:\\Development\\apache-forrest-0.8/plugins,C\:\\Development\\apache-forrest-0.8/whiteboard/plugins
26
- project.logger=debug
27
- project.cocoon-work-dir=C\:\\Development\\workspace\\ai4r\\site\\build\\tmp\\cocoon-work
28
- project.schema-dir=src/documentation/resources/schema
29
- project.status=status.xml
30
- project.xdocs-dir=src/documentation/content/xdocs
31
- project.required.plugins=org.apache.forrest.plugin.output.pdf
32
- project.bugtracking-url=http\://issues.apache.org/jira/browse/
33
- project.skins-dir=src/documentation/skins
34
- project.i18n=true
35
- project.catalog=src/documentation/resources/schema/catalog.xcat
36
- project.site-dir=C\:\\Development\\workspace\\ai4r\\site\\build\\site\\en
37
- project.site=site
38
- project.raw-content-dir=src/documentation/content
39
- project.content-dir=src/documentation
40
- project.logkitfile=C\:\\Development\\apache-forrest-0.8\\main\\webapp/WEB-INF/logkit.xconf
41
- project.home=C\:\\Development\\workspace\\ai4r\\site
1
+ #Ant properties
2
+ #Fri Mar 06 14:54:15 GMT 2009
3
+ project.sitemap=src/documentation/sitemap.xmap
4
+ project.war=/home/sfierens/workspace/ai4r/site/build/my-project.war
5
+ project.name=my-project
6
+ project.brokenlinkfile=/home/sfierens/workspace/ai4r/site/build/tmp/brokenlinks.xml
7
+ project.stylesheets-dir=src/documentation/resources/stylesheets
8
+ project.webapp=/home/sfierens/workspace/ai4r/site/build/webapp
9
+ project.skinconf=src/documentation/skinconf.xml
10
+ project.debuglevel=ERROR
11
+ project.skin=pelt
12
+ project.configfile=/usr/local/forrest/main/webapp/WEB-INF/cli.xconf
13
+ project.images-dir=src/documentation/resources/images
14
+ project.conf-dir=src/documentation/conf
15
+ project.temp-dir=/home/sfierens/workspace/ai4r/site/build/tmp
16
+ project.translations-dir=src/documentation/translations
17
+ project.menu-scheme=tab_attributes
18
+ project.lib-dir=src/documentation/lib
19
+ project.build-dir=/home/sfierens/workspace/ai4r/site/build
20
+ project.classes-dir=src/documentation/classes
21
+ project.resources-dir=src/documentation/resources
22
+ project.grammars-dir=src/documentation/resources/grammars
23
+ project.start-uri=linkmap.html
24
+ project.sitemap-dir=src/documentation
25
+ project.required.plugins.src=/usr/local/forrest/plugins,/usr/local/forrest/whiteboard/plugins
26
+ project.logger=debug
27
+ project.cocoon-work-dir=/home/sfierens/workspace/ai4r/site/build/tmp/cocoon-work
28
+ project.schema-dir=src/documentation/resources/schema
29
+ project.status=status.xml
30
+ project.xdocs-dir=src/documentation/content/xdocs
31
+ project.required.plugins=org.apache.forrest.plugin.output.pdf
32
+ project.bugtracking-url=http\://issues.apache.org/jira/browse/
33
+ project.skins-dir=src/documentation/skins
34
+ project.i18n=true
35
+ project.catalog=src/documentation/resources/schema/catalog.xcat
36
+ project.site-dir=/home/sfierens/workspace/ai4r/site/build/site/en
37
+ project.site=site
38
+ project.raw-content-dir=src/documentation/content
39
+ project.content-dir=src/documentation
40
+ project.logkitfile=/usr/local/forrest/main/webapp/WEB-INF/logkit.xconf
41
+ project.home=/home/sfierens/workspace/ai4r/site