Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for getWrapperClassIfPrimitive (0.09 sec)

  1. src/test/java/org/codelibs/core/lang/ClassUtilTest.java

        /**
         *
         */
        @Test
        public void testGetWrapperClassIfWrapper() {
            assertThat(ClassUtil.getWrapperClassIfPrimitive(int.class), is(sameClass(Integer.class)));
            assertThat(ClassUtil.getWrapperClassIfPrimitive(String.class), is(sameClass(String.class)));
            assertThat(ClassUtil.getWrapperClassIfPrimitive(byte.class), is(sameClass(Byte.class)));
        }
    
        /**
         *
         */
        @Test
    Registered: Fri Nov 01 20:58:10 UTC 2024
    - Last Modified: Thu Mar 07 01:59:08 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  2. src/main/java/org/codelibs/core/lang/ClassUtil.java

         *
         * @param clazz
         *            クラス。{@literal null}であってはいけません
         * @return 引数がプリミティブクラスならラッパークラス、それ以外の場合は引数で渡されたクラス
         */
        public static Class<?> getWrapperClassIfPrimitive(final Class<?> clazz) {
            assertArgumentNotNull("clazz", clazz);
    
            final Class<?> ret = getWrapperClass(clazz);
            if (ret != null) {
                return ret;
            }
    Registered: Fri Nov 01 20:58:10 UTC 2024
    - Last Modified: Thu Mar 07 01:59:08 UTC 2024
    - 27.5K bytes
    - Viewed (0)
Back to top