com.fabula.timeline.service
Class Helpers

java.lang.Object
  extended by com.fabula.timeline.service.Helpers

public class Helpers
extends java.lang.Object


Constructor Summary
Helpers()
           
 
Method Summary
static Mood getAverageMood(java.util.List<Event> moodEvents)
          This method calculates the average of a list of moods.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Helpers

public Helpers()
Method Detail

getAverageMood

public static Mood getAverageMood(java.util.List<Event> moodEvents)
This method calculates the average of a list of moods. The current algorithm takes the 10 last inserted moods to get the "trend".

Parameters:
moodEvents - List of moods to calculate average from
Returns:
The average Mood