Class Utility


  • public class Utility
    extends Object
    Author:
    Luca Frosini (ISTI - CNR)
    • Field Detail

      • UTC_TIMEZONE

        public static TimeZone UTC_TIMEZONE
    • Constructor Detail

      • Utility

        public Utility()
    • Method Detail

      • getHumanReadableDuration

        public static String getHumanReadableDuration​(long duration)
      • getUTCDateFormat

        public static DateFormat getUTCDateFormat​(String pattern)
      • getUTCCalendarInstance

        public static Calendar getUTCCalendarInstance()
      • getAggregationStartCalendar

        public static Calendar getAggregationStartCalendar​(int year,
                                                           int month,
                                                           int day)
      • getEndCalendarFromStartCalendar

        public static Calendar getEndCalendarFromStartCalendar​(AggregationType aggregationType,
                                                               Calendar aggregationStartCalendar,
                                                               int offset)
      • getEndDateFromStartDate

        public static Date getEndDateFromStartDate​(AggregationType aggregationType,
                                                   Date aggregationStartDate,
                                                   int offset)
      • getClientInfo

        protected static org.gcube.common.authorization.library.provider.ClientInfo getClientInfo()
                                                                                           throws Exception
        Throws:
        Exception
      • getMalformatedFile

        public static File getMalformatedFile​(File aggregateRecordsBackupFile)