Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
私はJavaで2つのスレッドを持っていて、それらを接続したいです。クラス PipedInputStream と PipedOutputStream を使用しましたが、オブジェクトを送信したいのですが、どうすればよいですか? ありがとうございました
を使用しないのはなぜですかQueue。プロデューサは、コンシューマが受信して処理できるキュー上のオブジェクトをポンプします。
Queue
BlockingQueueJava で使用できる実装がいくつかありますLinkedBlockingQueue。
BlockingQueue
LinkedBlockingQueue
特定のユースケースがある場合は、詳しく説明する必要があります。