private static ArrayList<GregorianCalendar> parseInputToGregorianCalendar(String input[],
			ArrayList<GregorianCalendar> defaultDate)
	{
		ArrayList<GregorianCalendar> result = new ArrayList<GregorianCalendar>();
		SimpleDateFormat sdf = new SimpleDateFormat();
		for (int i = 0; i < input.length; i++) {
			sdf.applyPattern("dd.MM.yyy");
			result.add(new GregorianCalendar());
			try {
				result.get(i).setTime(sdf.parse(input[i]));
				if (input.length == 1) {
					result.add((GregorianCalendar) result.get(i).clone());
					result.get(i + 1).add(GregorianCalendar.DAY_OF_YEAR, 1);
					result.get(i + 1).add(GregorianCalendar.SECOND, -1);
				} else if (i != 0) {
					result.get(i).add(GregorianCalendar.DAY_OF_YEAR, 1);
					result.get(i).add(GregorianCalendar.SECOND, -1);
				}
			} catch (ParseException e) {
				sdf.applyPattern("MM.yyy");
				try {
					result.get(i).setTime(sdf.parse(input[i]));
					if (input.length == 1) {
						result.add((GregorianCalendar) result.get(i).clone());
						result.get(i + 1).add(GregorianCalendar.MONTH, 1);
						result.get(i + 1).add(GregorianCalendar.SECOND, -1);
					} else if (i != 0) {
						result.get(i).add(GregorianCalendar.MONTH, 1);
						result.get(i).add(GregorianCalendar.SECOND, -1);
					}
				} catch (ParseException e1) {
					result = defaultDate;
				}
			}
		}
		return result;
	}