@Override
    public int buffersProcessed()
    {
        processed = 0;
        
        // Stream buffers can only be queued for streaming sources:
        if( errorCheck( channelType != SoundSystemConfig.TYPE_STREAMING,
                        "Buffers may only be queued for streaming sources." ) )
        {
            if( streamBuffers != null )
                streamBuffers.clear();
            return 0;
        }
        
        // Make sure we have a SourceDataLine:
        if( sourceDataLine == null )
        {
            if( streamBuffers != null )
                streamBuffers.clear();
            return 0;
        }
        
        if( sourceDataLine.available() > 0 )
        {
            processed = 1;
        }
        
        return processed;
    }