1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-02 06:35:28 +02:00

Bugzilla 220446. Changed the spelling of excercises to exercises throuhgout the code/examples and build processes.

This commit is contained in:
Randy Rohrbach 2008-03-12 20:54:36 +00:00
parent c27cddf3c7
commit 7586dfa95a
12 changed files with 49 additions and 49 deletions

View file

@ -37,7 +37,7 @@
<delete dir="src/@{packagedir}"/>
<mkdir dir="src/@{packagedir}"/>
<mkdir dir="src/@{packagedir}/answers"/>
<preprocess destdir="src/@{packagedir}" symbols="excercises">
<preprocess destdir="src/@{packagedir}" symbols="exercises">
<fileset dir="src_preprocess/@{packagedir}"/>
</preprocess>
<preprocess destdir="src/@{packagedir}/answers" symbols="answers">

View file

@ -24,8 +24,8 @@ import org.eclipse.debug.internal.ui.viewers.model.provisional.IPresentationCont
* IDMContext.getAdapter() and IVMContext.getAdapter() methods,
* which both call {@link DsfSession#getModelAdapter(Class)}.
* <p>
* The adapter implementation for this excercise is hard-coded to provide
* contents for only one view. In turn the view contens are determined using
* The adapter implementation for this exercise is hard-coded to provide
* contents for only one view. In turn the view contents are determined using
* the configurable ViewModelProvider. For demonstration purposes, this model
* adapter has two different layout configurations that can be used. These
* layout configurations can be set by calling the {@link #setViewLayout} method.

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.dataviewer;
//#else
//#package org.eclipse.dd.examples.dsf.dataviewer.answers;

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.dataviewer;
//#else
//#package org.eclipse.dd.examples.dsf.dataviewer.answers;
@ -49,7 +49,7 @@ import org.eclipse.dd.examples.dsf.DsfExamplesPlugin;
* be accessed while running in the executor thread.
* </p>
*/
//#ifdef excercises
//#ifdef exercises
//TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
//indicating allowed thread access to this class/method/member
//#else
@ -59,8 +59,8 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
// Request objects are used to serialize the interface calls into objects
// which can then be pushed into a queue.
//#ifdef excercises
// TODO Excercise 4 - Add an annotationindicating allowed concurrency access
//#ifdef exercises
// TODO Ecercise 4 - Add an annotationindicating allowed concurrency access
// Hint: Request and its subclasses have all their fields declared as final.
//#else
//# @Immutable
@ -73,7 +73,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -85,7 +85,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -100,7 +100,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
// The executor used to access all internal data of the generator.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
// Hint: If a member does not have an annotation, the programmer can assume
@ -113,7 +113,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
// and shutdown() methods write into the queue, while the serviceQueue()
// method reads from it.
// The executor used to access all internal data of the generator.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -123,7 +123,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
// List of listeners is not synchronized, it also has to be accessed
// using the executor.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -132,7 +132,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
private List<Listener> fListeners = new LinkedList<Listener>();
// Current number of elements in this generator.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -141,7 +141,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
private int fCount = MIN_COUNT;
// Counter used to determine when to reset the element count.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -150,7 +150,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
private int fCountResetTrigger = 0;
// Elements which were modified since the last reset.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -159,7 +159,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
private Set<Integer> fChangedIndexes = new HashSet<Integer>();
// Flag used to ensure that requests are processed sequentially.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -167,7 +167,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
//#endif
private boolean fServiceQueueInProgress = false;
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#endif
@ -187,7 +187,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
TimeUnit.MILLISECONDS);
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#endif
@ -214,7 +214,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#endif
@ -232,7 +232,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#endif
@ -250,7 +250,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#endif
@ -264,7 +264,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
} catch (RejectedExecutionException e) {}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#endif
@ -279,7 +279,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
// Main processing function of this generator.
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -287,8 +287,8 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
//#endif
private void serviceQueue() {
//#ifdef excercises
// TODO Excercise 3 - Add logic to discard requests from queue.
//#ifdef exercises
// TODO Exercise 3 - Add logic to discard cancelled requests from queue.
// Hint: Since serviceQueue() is called using the executor, and the
// fQueue list can only be modified when running in the executor
// thread. This method can safely iterate and modify fQueue without
@ -335,7 +335,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -349,7 +349,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
rm.done();
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -370,7 +370,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
/**
* This method simulates changes in the supplier's data set.
*/
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -389,7 +389,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
/**
* Calculates new size for provider's data set.
*/
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else
@ -412,7 +412,7 @@ public class DataGeneratorWithExecutor implements IDataGenerator {
/**
* Invalidates a random range of indexes.
*/
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.dataviewer;
//#else
//#package org.eclipse.dd.examples.dsf.dataviewer.answers;

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.dataviewer;
//#else
//#package org.eclipse.dd.examples.dsf.dataviewer.answers;
@ -29,7 +29,7 @@ import org.eclipse.dd.dsf.concurrent.RequestMonitor;
* view to receive events indicating when the data supplied by the generator
* is changed.
*/
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 4 - Add an annotation (ThreadSafe/ConfinedToDsfExecutor)
// indicating allowed thread access to this class/method/member
//#else

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.dataviewer;
//#else
//#package org.eclipse.dd.examples.dsf.dataviewer.answers;
@ -122,8 +122,8 @@ public class SyncDataViewer
}
private void refreshViewer() {
//#ifdef excercises
// TODO Excercise 5 - Add a call to getElements() to force a deadlock.
//#ifdef exercises
// TODO Exercise 5 - Add a call to getElements() to force a deadlock.
//#else
//# getElements(null);
//#endif
@ -154,8 +154,8 @@ public class SyncDataViewer
tableViewer.getControl().setLayoutData(data);
// Create the data generator.
//#ifdef excercises
// TODO Excercise 5 - Use the DataGeneratorWithExecutor() instead.
//#ifdef exercises
// TODO Exercise 5 - Use the DataGeneratorWithExecutor() instead.
final IDataGenerator generator = new DataGeneratorWithThread();
//#else
//# final IDataGenerator generator = new DataGeneratorWithExecutor();

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.requestmonitor;
//#else
//#package org.eclipse.dd.examples.dsf.requestmonitor.answers;

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.requestmonitor;
//#else
//#package org.eclipse.dd.examples.dsf.requestmonitor.answers;
@ -37,7 +37,7 @@ public class AsyncHelloWorld {
static void asyncHelloWorld(RequestMonitor rm) {
System.out.println("Hello world");
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 1: - Call the second async. "Hello world 2" method.
// Hint: Calling an asynchronous method requires passing to it a
// request monitor. A new request monitor can be constructed with
@ -51,7 +51,7 @@ public class AsyncHelloWorld {
//#endif
}
//#ifdef excercises
//#ifdef exercises
// TODO: Exercise 1 - Add a second async. "Hello world 2" method.
//#else
//# static void asyncHelloWorld2(RequestMonitor rm) {

View file

@ -8,7 +8,7 @@
* Contributors:
* Wind River Systems - initial API and implementation
*******************************************************************************/
//#ifdef excercises
//#ifdef exercises
package org.eclipse.dd.examples.dsf.requestmonitor;
//#else
//#package org.eclipse.dd.examples.dsf.requestmonitor.answers;
@ -51,7 +51,7 @@ public class AsyncQuicksort {
{
if (right > left) {
int pivot = left;
//#ifdef excercises
//#ifdef exercises
// TODO: Exercise 2 - Convert the call to partition into an
// asynchronous call to asyncPartition().
// Hint: The rest of the code below should be executed inside
@ -84,7 +84,7 @@ public class AsyncQuicksort {
}
}
//#ifdef excercises
//#ifdef exercises
// TODO Exercise 2 - Convert partition to an asynchronous method.
// Hint: a DataRequestMonitor<Integer> should be used to carry the
// return value to the caller.
@ -108,7 +108,7 @@ public class AsyncQuicksort {
array[right] = array[store];
array[store] = pivotValue;
//#ifdef excercises
//#ifdef exercises
// TODO: Request Monitors Exercise 2 - Return the data to caller using
// a request monitor.
return store;

View file

@ -31,7 +31,7 @@ import org.junit.Before;
import org.junit.Test;
/**
* Tests that excercise the Query object.
* Tests that exercise the Query object.
*/
public class DsfQueryTests {
TestDsfExecutor fExecutor;

View file

@ -30,7 +30,7 @@ import org.junit.Before;
import org.junit.Test;
/**
* Tests that excercise the Sequence object.
* Tests that exercise the Sequence object.
*/
public class DsfSequenceTests {
TestDsfExecutor fExecutor;