I have a producer-consumer scenario. Class A creates objects of type E. Do I have to store it in a static data structure in class A, because the consumer logic should be processed in class B, which does not have a reference to object A. Is LinkedBlockingQueue the correct data type for the queue? Or is there a better choice for this?
source
share