|
1 | 1 | <?xml version="1.0" ?> |
2 | 2 |
|
3 | | -<project |
4 | | - basedir="." |
5 | | - default="build" |
6 | | - name="Thinking in Java, 4th Edition (Refreshed) by Bruce Eckel (chapter: patterns)"> |
7 | | - |
8 | | - <description> |
9 | | - build.xml for the source code for the patterns chapter of |
10 | | - Thinking in Java, 4th Edition (Refreshed) by Bruce Eckel |
11 | | - Source code available at http://www.MindView.net |
12 | | - See copyright notice in CopyRight.txt |
13 | | - |
14 | | - Ant available from: http://ant.apache.org/ |
15 | | - |
16 | | - To see options, type: ant -p |
17 | | - </description> |
18 | | - |
19 | | - <condition property="version1.8"> |
20 | | - <equals arg1="1.8" arg2="${ant.java.version}"/> |
21 | | - </condition> |
22 | | - |
23 | | - <target name="net_mindview_util"> |
24 | | - <javac includeantruntime="false" |
25 | | - classpath="${java.class.path};${basedir};${basedir}/.." |
26 | | - srcdir="${basedir}/../net/mindview/util/"> |
27 | | - <compilerarg value="-Xmaxerrs"/> |
28 | | - <compilerarg value="10"/> |
29 | | - </javac> |
30 | | - </target> |
31 | | - |
32 | | - <target |
33 | | - depends="net_mindview_util" |
34 | | - description="Build all classes in this directory" |
35 | | - name="build"> |
36 | | - <fail message="J2SE8 required" unless="version1.8"/> |
37 | | - <echo message="Building 'patterns'"/> |
38 | | - <javac includeantruntime="false" |
39 | | - classpath="${java.class.path};${basedir};${basedir}/.." |
40 | | - debug="true" |
41 | | - srcdir="${basedir}"> |
42 | | - <compilerarg value="-Xmaxerrs"/> |
43 | | - <compilerarg value="10"/> |
44 | | - </javac> |
45 | | - <echo message="Build 'patterns' succeeded"/> |
46 | | - </target> |
47 | | - |
| 3 | +<project default="run"> |
| 4 | + <property name="chapter" value="Design Patterns"/> |
| 5 | + <import file="../Ant-Common.xml"/> |
48 | 6 |
|
49 | 7 | <target |
50 | 8 | depends="build" |
51 | 9 | description="Compile and run" |
52 | 10 | name="run"> |
53 | 11 | <touch file="failures"/> |
54 | | - <antcall target="ActiveObjectDemo"/> |
55 | | - <antcall target="AtomicIntegerTest"/> |
56 | | - <antcall target="AtomicityTest"/> |
57 | | - <antcall target="AttemptLocking"/> |
58 | | - <antcall target="BankTellerSimulation"/> |
59 | | - <antcall target="BasicThreads"/> |
60 | | - <antcall target="CachedThreadPool"/> |
61 | | - <antcall target="CallableDemo"/> |
62 | | - <antcall target="CaptureUncaughtException"/> |
63 | | - <antcall target="CarBuilder"/> |
64 | | - <antcall target="CountDownLatchDemo"/> |
65 | | - <antcall target="CriticalSection"/> |
66 | | - <antcall target="DaemonFromFactory"/> |
67 | | - <antcall target="Daemons"/> |
68 | | - <antcall target="DaemonsDontRunFinally"/> |
69 | | - <antcall target="DeadlockingDiningPhilosophers"/> |
70 | | - <antcall target="DelayQueueDemo"/> |
71 | | - <antcall target="EvenGenerator"/> |
72 | | - <antcall target="ExceptionThread"/> |
73 | | - <antcall target="ExchangerDemo"/> |
74 | | - <antcall target="ExplicitCriticalSection"/> |
75 | | - <antcall target="FastSimulation"/> |
76 | | - <antcall target="FixedDiningPhilosophers"/> |
77 | | - <antcall target="FixedThreadPool"/> |
78 | | - <antcall target="GreenhouseScheduler"/> |
79 | | - <antcall target="HorseRace"/> |
80 | | - <antcall target="Interrupting"/> |
81 | | - <antcall target="Interrupting2"/> |
82 | | - <antcall target="InterruptingIdiom"/> |
83 | | - <antcall target="Joining"/> |
84 | | - <antcall target="ListComparisons"/> |
85 | | - <antcall target="MainThread"/> |
86 | | - <antcall target="MapComparisons"/> |
87 | | - <antcall target="MoreBasicThreads"/> |
88 | | - <antcall target="MultiLock"/> |
89 | | - <antcall target="NaiveExceptionHandling"/> |
90 | | - <antcall target="NIOInterruption"/> |
91 | | - <antcall target="NotifyVsNotifyAll"/> |
92 | | - <antcall target="OrnamentalGarden"/> |
93 | | - <antcall target="PipedIO"/> |
94 | | - <antcall target="PriorityBlockingQueueDemo"/> |
95 | | - <antcall target="ReaderWriterList"/> |
96 | | - <antcall target="Restaurant"/> |
97 | | - <antcall target="SelfManaged"/> |
98 | | - <antcall target="SemaphoreDemo"/> |
99 | | - <antcall target="SerialNumberChecker"/> |
100 | | - <antcall target="SettingDefaultHandler"/> |
101 | | - <antcall target="SimpleDaemons"/> |
102 | | - <antcall target="SimpleMicroBenchmark"/> |
103 | | - <antcall target="SimplePriorities"/> |
104 | | - <antcall target="SimpleThread"/> |
105 | | - <antcall target="SingleThreadExecutor"/> |
106 | | - <antcall target="SleepingTask"/> |
107 | | - <antcall target="SynchronizationComparisons"/> |
108 | | - <antcall target="SyncObject"/> |
109 | | - <antcall target="ThreadLocalVariableHolder"/> |
110 | | - <antcall target="ThreadVariations"/> |
111 | | - <antcall target="ToastOMatic"/> |
112 | | - <antcall target="RestaurantWithQueues"/> |
113 | | - <antcall target="WaxOMatic"/> |
114 | | - <antcall target="WaxOMatic2"/> |
115 | | - <antcall target="Atomicity"/> |
116 | | - <echo |
117 | | - message="* AtomicEvenGenerator must be run by hand *"/> |
118 | | - <echo message="* CloseResource must be run by hand *"/> |
119 | | - <echo message="* MutexEvenGenerator must be run by hand *"/> |
120 | | - <echo message="* ResponsiveUI must be run by hand *"/> |
121 | | - <echo |
122 | | - message="* SynchronizedEvenGenerator must be run by hand *"/> |
123 | | - <echo message="* TestBlockingQueues must be run by hand *"/> |
| 12 | + <jrun cls="Adapter" /> |
| 13 | + <jrun cls="BeeAndFlowers" /> |
| 14 | + <jrun cls="BoxObserver" /> |
| 15 | + <jrun cls="ChainOfResponsibility" /> |
| 16 | + <jrun cls="CommandPattern" /> |
| 17 | + <jrun cls="Facade" /> |
| 18 | + <jrun cls="GameEnvironment" /> |
| 19 | + <jrun cls="ObservedFlower" /> |
| 20 | + <jrun cls="PaperScissorsRock" /> |
| 21 | + <jrun cls="ProxyDemo" /> |
| 22 | + <jrun cls="ShapeFactory1" /> |
| 23 | + <jrun cls="ShapeFactory2" /> |
| 24 | + <jrun cls="SingletonPattern" /> |
| 25 | + <jrun cls="StateDemo" /> |
| 26 | + <jrun cls="StateMachineDemo" /> |
| 27 | + <jrun cls="StrategyPattern" /> |
| 28 | + <jrun cls="TemplateMethod" /> |
124 | 29 | <delete file="failures"/> |
125 | 30 | </target> |
126 | 31 |
|
127 | | - <target description="delete all byproducts" name="clean"> |
128 | | - <delete> |
129 | | - <fileset dir="${basedir}" includes="**/*.class"/> |
130 | | - <fileset dir="${basedir}" includes="**/*Output.txt"/> |
131 | | - <fileset dir="${basedir}" includes="**/log.txt"/> |
132 | | - <fileset dir="${basedir}" includes="failures"/> |
133 | | - </delete> |
134 | | - <echo message="clean successful"/> |
135 | | - </target> |
136 | | - |
137 | 32 | </project> |
138 | 33 |
|
139 | 34 |
|
0 commit comments