/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*
*/
/** The backend for the message queue abstraction. This class is
instantiated first and queried to provide the two "sides" of the
message queue. */
public class MessageQueueBackend {
// The two queues
public MessageQueueBackend() {
}
/** Get one of the two symmetric sides of this message queue. */
return leftRightQueue;
}
/** Get second of the two symmetric sides of this message queue. */
return rightLeftQueue;
}
}
synchronized(readList) {
try {
}
catch (InterruptedException e) {
}
}
return readList.removeFirst();
}
}
synchronized(readList) {
if (millis == 0) {
return null;
}
try {
}
catch (InterruptedException e) {
}
}
// If list is still empty after wait, return null
return null;
}
return readList.removeFirst();
}
}
synchronized(writeList) {
}
}
}
}