Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for toBoolean (0.05 sec)

  1. src/main/java/org/codelibs/core/convert/BooleanConversionUtil.java

        }
    
        /**
         * Converts to {@link Boolean}.
         *
         * @param o
         *            The object to convert
         * @return The converted {@link Boolean}
         */
        public static Boolean toBoolean(final Object o) {
            return switch (o) {
            case null -> null;
            case Boolean b -> b;
            case Number n -> n.intValue() != 0;
            case String s -> switch (s.toLowerCase()) {
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Thu Jul 31 08:16:49 UTC 2025
    - 1.8K bytes
    - Viewed (0)
  2. android-test/build.gradle.kts

    @file:Suppress("UnstableApiUsage")
    
    plugins {
      id("com.android.library")
      kotlin("android")
      id("de.mannodermaus.android-junit5")
    }
    
    val androidBuild = property("androidBuild").toString().toBoolean()
    
    android {
      compileSdk = 35
    
      namespace = "okhttp.android.test"
    
      defaultConfig {
        minSdk = 21
    
        // Make sure to use the AndroidJUnitRunner (or a sub-class) in order to hook in the JUnit 5 Test Builder
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Tue Jul 29 20:01:04 UTC 2025
    - 3.8K bytes
    - Viewed (2)
  3. src/main/java/org/codelibs/core/convert/NumberConversionUtil.java

                if (s != null) {
                    return s;
                }
                return Short.valueOf((short) 0);
            } else if (type == boolean.class) {
                final Boolean b = BooleanConversionUtil.toBoolean(o);
                if (b != null) {
                    return b;
                }
                return Boolean.FALSE;
            } else if (type == byte.class) {
                final Byte b = ByteConversionUtil.toByte(o);
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Thu Jul 31 08:16:49 UTC 2025
    - 5.6K bytes
    - Viewed (0)
  4. src/main/java/org/codelibs/core/beans/impl/PropertyDescImpl.java

            } else if (java.util.Date.class.isAssignableFrom(propertyType)) {
                return (T) convertDate(arg);
            } else if (Boolean.class.isAssignableFrom(propertyType)) {
                return (T) BooleanConversionUtil.toBoolean(arg);
            } else if (arg != null && arg.getClass() != String.class && String.class == propertyType) {
                return (T) arg.toString();
            } else if (arg instanceof String && !String.class.equals(propertyType)) {
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Thu Jul 24 01:52:43 UTC 2025
    - 15.1K bytes
    - Viewed (0)
  5. README.md

    Integer value = IntegerConversionUtil.toInteger("123");        // Returns 123
    Integer nullValue = IntegerConversionUtil.toInteger(null);     // Returns null
    Boolean flag = BooleanConversionUtil.toBoolean("true");        // Returns true
    Date date = DateConversionUtil.toDate("2023-12-25", "yyyy-MM-dd");
    
    // Primitive conversions with default values
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Sun Aug 31 02:56:02 UTC 2025
    - 12.7K bytes
    - Viewed (0)
Back to top