org.joda.time.tz.Provider Java Examples
The following examples show how to use
org.joda.time.tz.Provider.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Nopol2017_0089_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #2
Source File: DateTimeZone.java From astor with GNU General Public License v2.0 | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #3
Source File: Time_9_DateTimeZone_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #4
Source File: Cardumen_00239_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #5
Source File: Time_9_DateTimeZone_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #6
Source File: Cardumen_00239_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #7
Source File: Time_8_DateTimeZone_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #8
Source File: Cardumen_00189_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #9
Source File: Time_8_DateTimeZone_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #10
Source File: Cardumen_00189_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #11
Source File: Time_19_DateTimeZone_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #12
Source File: Cardumen_0074_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #13
Source File: Time_19_DateTimeZone_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #14
Source File: Time_23_DateTimeZone_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #15
Source File: Cardumen_00282_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #16
Source File: Time_23_DateTimeZone_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #17
Source File: Cardumen_0070_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #18
Source File: Time_17_DateTimeZone_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #19
Source File: Cardumen_0070_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #20
Source File: Time_17_DateTimeZone_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #21
Source File: Cardumen_00137_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #22
Source File: DateTimeZone.java From astor with GNU General Public License v2.0 | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #23
Source File: Time_25_DateTimeZone_s.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #24
Source File: Cardumen_00137_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #25
Source File: Time_25_DateTimeZone_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #26
Source File: Nopol2017_0089_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #27
Source File: Cardumen_00282_t.java From coming with MIT License | 6 votes |
/** * Sets the zone provider factory without performing the security check. * * @param provider provider to use, or null for default * @throws IllegalArgumentException if the provider is invalid */ private static void setProvider0(Provider provider) { if (provider == null) { provider = getDefaultProvider(); } Set<String> ids = provider.getAvailableIDs(); if (ids == null || ids.size() == 0) { throw new IllegalArgumentException ("The provider doesn't have any available ids"); } if (!ids.contains("UTC")) { throw new IllegalArgumentException("The provider doesn't support UTC"); } if (!UTC.equals(provider.getZone("UTC"))) { throw new IllegalArgumentException("Invalid UTC zone provided"); } cProvider = provider; cAvailableIDs = ids; }
Example #28
Source File: Time_25_DateTimeZone_s.java From coming with MIT License | 3 votes |
/** * Sets the zone provider factory. * <p> * The zone provider is a pluggable instance factory that supplies the * actual instances of DateTimeZone. * * @param provider provider to use, or null for default * @throws SecurityException if you do not have the permission DateTimeZone.setProvider * @throws IllegalArgumentException if the provider is invalid */ public static void setProvider(Provider provider) throws SecurityException { SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(new JodaTimePermission("DateTimeZone.setProvider")); } setProvider0(provider); }
Example #29
Source File: Time_19_DateTimeZone_t.java From coming with MIT License | 3 votes |
/** * Sets the zone provider factory. * <p> * The zone provider is a pluggable instance factory that supplies the * actual instances of DateTimeZone. * * @param provider provider to use, or null for default * @throws SecurityException if you do not have the permission DateTimeZone.setProvider * @throws IllegalArgumentException if the provider is invalid */ public static void setProvider(Provider provider) throws SecurityException { SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(new JodaTimePermission("DateTimeZone.setProvider")); } setProvider0(provider); }
Example #30
Source File: Time_19_DateTimeZone_s.java From coming with MIT License | 3 votes |
/** * Sets the zone provider factory. * <p> * The zone provider is a pluggable instance factory that supplies the * actual instances of DateTimeZone. * * @param provider provider to use, or null for default * @throws SecurityException if you do not have the permission DateTimeZone.setProvider * @throws IllegalArgumentException if the provider is invalid */ public static void setProvider(Provider provider) throws SecurityException { SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(new JodaTimePermission("DateTimeZone.setProvider")); } setProvider0(provider); }