public synchronized void release() { if (player != null) { player.removePlayerListener(this); player.close(); } player = null; }