Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 41 for setTimezone (0.35 sec)

  1. src/test/java/org/codelibs/core/convert/TimeConversionUtilTest.java

         */
        @Test
        public void testToDate_LongStyle() throws Exception {
            final Date date = toDate("11:49:10 JST");
            final SimpleDateFormat df = new SimpleDateFormat("HH:mm:ss");
            df.setTimeZone(TimeZone.getTimeZone("JST"));
            assertThat(df.format(date), is("11:49:10"));
        }
    
        /**
         * @throws Exception
         */
        @Test
        public void testToDate_FullStyle() throws Exception {
    Registered: Wed Jun 12 12:50:12 UTC 2024
    - Last Modified: Thu Mar 07 01:59:08 UTC 2024
    - 9.5K bytes
    - Viewed (0)
  2. src/test/java/org/codelibs/core/convert/TimestampConversionUtilTest.java

        //        final Date date = toDate("2010/09/07 11:49:10 JST", Locale.JAPAN);
        //        final SimpleDateFormat df = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
        //        df.setTimeZone(TimeZone.getTimeZone("JST"));
        //        assertThat(df.format(date), is("2010/09/07 11:49:10"));
        //    }
    
        /**
         * @throws Exception
         */
        //    @Test
    Registered: Wed Jun 12 12:50:12 UTC 2024
    - Last Modified: Thu Mar 07 01:59:08 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  3. maven-api-impl/src/main/java/org/apache/maven/internal/impl/model/MavenBuildTimestamp.java

                time = Instant.now();
            }
            SimpleDateFormat dateFormat = new SimpleDateFormat(timestampFormat);
            dateFormat.setCalendar(new GregorianCalendar());
            dateFormat.setTimeZone(DEFAULT_BUILD_TIME_ZONE);
            formattedTimestamp = dateFormat.format(new Date(time.toEpochMilli()));
        }
    
        public String formattedTimestamp() {
            return formattedTimestamp;
        }
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Fri Apr 12 10:50:18 UTC 2024
    - 2.8K bytes
    - Viewed (0)
  4. maven-model-builder/src/main/java/org/apache/maven/model/interpolation/MavenBuildTimestamp.java

            if (time == null) {
                time = new Date();
            }
            SimpleDateFormat dateFormat = new SimpleDateFormat(timestampFormat);
            dateFormat.setCalendar(new GregorianCalendar());
            dateFormat.setTimeZone(DEFAULT_BUILD_TIME_ZONE);
            formattedTimestamp = dateFormat.format(time);
        }
    
        public String formattedTimestamp() {
            return formattedTimestamp;
        }
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Tue Nov 22 13:26:01 UTC 2022
    - 2.7K bytes
    - Viewed (0)
  5. testing/internal-performance-testing/src/main/groovy/org/gradle/performance/results/FormatSupport.java

            return format(date, "yyyy-MM-dd");
        }
    
        private static String format(Date date, String format) {
            DateFormat timeStampFormat = new SimpleDateFormat(format);
            timeStampFormat.setTimeZone(TimeZone.getTimeZone("UTC"));
            return timeStampFormat.format(date);
        }
    
        public static Number getTotalTimeSeconds(MeasuredOperationList baseline, MeasuredOperationList current) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 4K bytes
    - Viewed (0)
  6. maven-model-builder/src/test/java/org/apache/maven/model/interpolation/AbstractModelInterpolatorTest.java

        public void testDefaultBuildTimestampFormatWithLocalTimeZoneMidnightRollover() {
            Calendar cal = Calendar.getInstance();
            cal.setTimeZone(TimeZone.getTimeZone("Europe/Berlin"));
    
            cal.set(Calendar.HOUR_OF_DAY, 1);
            cal.set(Calendar.MINUTE, 16);
            cal.set(Calendar.SECOND, 0);
            cal.set(Calendar.YEAR, 2014);
            cal.set(Calendar.MONTH, Calendar.JUNE);
            cal.set(Calendar.DATE, 16);
    
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Mon Feb 26 17:04:44 UTC 2024
    - 22.2K bytes
    - Viewed (0)
  7. testing/smoke-test/src/smokeTest/groovy/org/gradle/smoketests/AbstractGradleceptionSmokeTest.groovy

            newTimestampDateFormat().format(new Date())
        }
    
        static SimpleDateFormat newTimestampDateFormat() {
            new SimpleDateFormat('yyyyMMddHHmmssZ').tap {
                setTimeZone(TimeZone.getTimeZone("UTC"))
            }
        }
    
        static class GradleBuildJvmSpec implements Spec<JvmInstallationMetadata> {
    
            static boolean isAvailable() {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Apr 04 07:21:38 UTC 2024
    - 4K bytes
    - Viewed (0)
  8. maven-resolver-provider/src/test/java/org/apache/maven/repository/internal/RemoteSnapshotMetadataTest.java

            Locale.setDefault(defaultLocale);
        }
    
        static String gregorianDate() {
            SimpleDateFormat df = new SimpleDateFormat("yyyyMMdd");
            df.setCalendar(new GregorianCalendar());
            df.setTimeZone(RemoteSnapshotMetadata.DEFAULT_SNAPSHOT_TIME_ZONE);
            return df.format(new Date());
        }
    
        @Test
        void gregorianCalendarIsUsed() {
            String dateBefore = gregorianDate();
    
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Fri Feb 16 11:43:34 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  9. maven-resolver-provider/src/main/java/org/apache/maven/repository/internal/RemoteSnapshotMetadata.java

                DateFormat utcDateFormatter = new SimpleDateFormat(DEFAULT_SNAPSHOT_TIMESTAMP_FORMAT);
                utcDateFormatter.setCalendar(new GregorianCalendar());
                utcDateFormatter.setTimeZone(DEFAULT_SNAPSHOT_TIME_ZONE);
    
                snapshot = new Snapshot();
                snapshot.setBuildNumber(buildNumber != null ? buildNumber : getBuildNumber(recessive) + 1);
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Thu Apr 25 10:10:21 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  10. maven-api-impl/src/main/java/org/apache/maven/internal/impl/resolver/MavenMetadata.java

        static final String MAVEN_METADATA_XML = "maven-metadata.xml";
    
        static DateFormat fmt;
    
        static {
            TimeZone timezone = TimeZone.getTimeZone("UTC");
            fmt = new SimpleDateFormat("yyyyMMddHHmmss");
            fmt.setTimeZone(timezone);
        }
    
        protected Metadata metadata;
    
        private final Path path;
    
        protected final Date timestamp;
    
        private boolean merged;
    
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Thu May 02 16:33:18 UTC 2024
    - 4.4K bytes
    - Viewed (0)
Back to top