Switch CRLF to LF line endings.
[TD_SR.git] / TD1 / exo3 / Producteur.java
index f7f3c474b57e49d830ec32e6aeed80fff028d915..47a402180d5f8c9a6fa4854bc4b3b03f76c97858 100644 (file)
@@ -1,35 +1,35 @@
-import java.util.concurrent.ThreadLocalRandom;\r
-\r
-\r
-public class Producteur implements Runnable {\r
-\r
-       private BufferCirc buffer;\r
-       private int val;\r
-\r
-\r
-       public Producteur(BufferCirc b) {\r
-               buffer = b;\r
-       }\r
-\r
-       public Producteur(BufferCirc b, String name) {\r
-               buffer = b;\r
-               setThName(name);\r
-       }\r
-\r
-       public void setThName(String name) {\r
-               Thread.currentThread().setName(name);\r
-       }\r
-\r
-       public void run() {\r
-               while (true) {\r
-                       buffer.depose(new Integer(val));\r
-                       System.out.println (Thread.currentThread().getName() +  " a depose " + val);\r
-                       val++;\r
-                       try {\r
-                               Thread.sleep(ThreadLocalRandom.current().nextInt(101));\r
-                       }\r
-                       catch (InterruptedException e) {}\r
-               }\r
-       }\r
-\r
-} // fin classe Producteur\r
+import java.util.concurrent.ThreadLocalRandom;
+
+
+public class Producteur implements Runnable {
+
+       private BufferCirc buffer;
+       private int val;
+
+
+       public Producteur(BufferCirc b) {
+               buffer = b;
+       }
+
+       public Producteur(BufferCirc b, String name) {
+               buffer = b;
+               setThName(name);
+       }
+
+       public void setThName(String name) {
+               Thread.currentThread().setName(name);
+       }
+
+       public void run() {
+               while (true) {
+                       buffer.depose(new Integer(val));
+                       System.out.println (Thread.currentThread().getName() +  " a depose " + val);
+                       val++;
+                       try {
+                               Thread.sleep(ThreadLocalRandom.current().nextInt(101));
+                       }
+                       catch (InterruptedException e) {}
+               }
+       }
+
+} // fin classe Producteur