public int getOutcomeCategoryAppearances(IntervalDescription intDesc, String category, String countOption)
    {
    	int result = 0;
    	
    	for(int i=0; i < intervalsList.size(); i++)
    	{
    		LinkedList<interval> currentList = intervalsList.get(i);
    		if(!currentList.isEmpty())
    		{
    			interval firstInt = currentList.getFirst();
    			if(firstInt.intervalDescription == intDesc)
    			{ 				
    				for(interval interval: currentList)
    				{
    					for(IntervalResult intResult: interval.Results)
    					{

							if(intResult.strResult.equalsIgnoreCase(category))
							{
								/*
								 * If we are counting instants, just add 1.
								 * If we are counting intervals, add 1 when encountered and then break
								 * the results list (so that we don't add more)
								 */
								if(countOption.equalsIgnoreCase("instant"))
								{
									result++;
								}
								else
								{
									result ++;
									break;
								}
							}
    					}
    				}
    				break;
    			}
    		}
    	}						
    	
    	return result;
    }