public void setMaxSize(int newMaxSize)
    {
        if(newMaxSize < 0)
        {
            System.out.println("New size must be a nonnegative integer. " +
                    "maxCount has not been modified.");
            return;
        }
        
        if(newMaxSize == maxCount)
        {
            return;            
        }
        
        if(newMaxSize < this.maxCount && newMaxSize < this.queueCount)
        {
            int i = 0;
            
            for(Node<T> currentNode = this.firstNode; currentNode != null; currentNode = currentNode.link)
            {
                i++;
                
                if(i == newMaxSize)
                {
                    currentNode.link = null;
                    this.lastNode = currentNode;
                }
            }
            
            this.queueCount = newMaxSize;
        }
        
        this.maxCount = newMaxSize;
        return;        
        
    }//end setMaxSize()