
edu.uvm.ccts.arden.util.TimeUtil Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of arden-model Show documentation
Show all versions of arden-model Show documentation
The Java model used to represent Arden objects
/*
* Copyright 2015 The University of Vermont and State
* Agricultural College, Vermont Oxford Network, and The University
* of Vermont Medical Center. All rights reserved.
*
* Written by Matthew B. Storer
*
* This file is part of Arden Model.
*
* Arden Model is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Arden Model is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Arden Model. If not, see .
*/
package edu.uvm.ccts.arden.util;
import edu.uvm.ccts.arden.model.*;
import edu.uvm.ccts.common.util.DateUtil;
import java.text.ParseException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
/**
* Created by mstorer on 8/13/13.
*/
public class TimeUtil {
public static Time parseTime(String s) throws ParseException {
return new Time(DateUtil.parseDate(s));
}
public static TimeOfDay parseTimeOfDay(String s) throws ParseException {
return new TimeOfDay(parseTime(s));
}
public static Time mean(List
© 2015 - 2025 Weber Informatics LLC | Privacy Policy