Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
/**
 * This class is part of JCodec ( www.jcodec.org ) This software is distributed
 * under FreeBSD License
 * 
 * @author The JCodec project
 * 
 */

import java.util.concurrent.BlockingQueue;

public class Main {
    public static <E> void surePut(BlockingQueue<E> q, E el) {
        while (true) {
            try {
                q.put(el);
                break;
            } catch (InterruptedException e) {
            }
        }
    }
}