public void setNextAvailable ( boolean avail ) { // Check if the state has changed if ( nextAvailable != avail ) { // Keep the new state nextAvailable = avail ; // Notify any listeners fo the change in state firePropertyChange ( new PropertyChangeEvent ( this , "nextAvailable" , ! avail , avail ) ) ; } }
Sets the state of the next available flag and notifies any listeners of this change .