code: private String getTimePosition(String time, boolean first)
    {
  
      if (time == null)
      {
        return "undefined";
      }
  
      String[] splittedTimeAnno = time.split("-");
      if (splittedTimeAnno.length > 1)
      {
        if (first)
        {
          return splittedTimeAnno[0].equals("") ? "undefined"
            : splittedTimeAnno[0];
        }
        else
        {
          return splittedTimeAnno[1].equals("") ? "undefined"
            : splittedTimeAnno[1];
        }
      }
  
      if (first)
      {
        return splittedTimeAnno[0].equals("") ? "undefined" : splittedTimeAnno[0];
      }
  
      // if we want the end time, return undefined.
      return "undefined";
    }
docs: Split a time annotation s.ms-(s.ms)? Whether the flag first is set to true,
  we return the first value, otherwise we did try to return the second. The
  end time don't have to be annotated, in this case it returns "undefined".
  Without a defined start time the result is an empty String "undefined". If
  there is no time anno, it returns undefined
  
  @return "undefined", when time parameter is undefined