6 Unanswered Topics

Remove Filter
Member Avatar for
Member Avatar for CPT

i've just started learning the C# language and this is my first program to use threads. I don't understand why the consumer thread doesn't get called( only after the producer has stopped)and when it gets called it doesn't consume anything, also I've noticed that the majority of produced elements are …

0
181
Member Avatar for Baduizm

I Have This Workers List: private List<Worker> buildWorkerList( Producer producer ) { List<Worker> workerList = new ArrayList<Worker>( 11 ); workerList.add( new WorkerImpl( "Garnett", producer ) ); workerList.add( new WorkerImpl( "Durant", producer ) ); workerList.add( new WorkerImpl( "Xavier", producer ) ); workerList.add( new WorkerImpl( "Daniel", producer ) ); workerList.add( new WorkerImpl( …

0
154
Member Avatar for iRamble88

[CODE=java]import java.util.Scanner; class Sum { private int value; public int get() { return value; } public void set(int sum) { this.value = sum; } } class Summation extends Thread { private int upper; private int lower; private Sum sumValue; public Summation(int upper, Sum sumValue) { if (upper < 0) throw …

0
170
Member Avatar for arya6000

Hello I have the following code for a WPF application here is the code Code from MainWindow.xaml.cs [CODE] public partial class MainWindow : Window { public MainWindow() { InitializeComponent(); } private void button1_Click(object sender, RoutedEventArgs e) { Thread[] threads = new Thread[3]; for (int i = 0; i < 3; …

0
86
Member Avatar for andy1977

I have a WCF service in which I have one method, It gets new live auctions from the database. It is called every second. For each auctions WCF creates new thread and start the auction. This thread updates database every second and after auction ends that thread gets close. However …

0
96
Member Avatar for blackrobe

Hey there, I'm currently using NetBeans 6.8 running Cygwin GNU Bash version 3.2.49(23)-release. I'm having a problem running my program that uses pthreads, mutexes, and semaphores. After it creates 1 to 3-4 threads, it returns a Segmentation fault. I ran the program on a computer running Linux (using NetBeans as …

0
115

The End.