Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 171 for newInstance (0.04 sec)

  1. src/test/java/jcifs/spnego/SpnegoConstantsTest.java

        }
    
        @Test
        @DisplayName("Interface cannot be instantiated")
        @SuppressWarnings("deprecation") // Using Class#newInstance for explicit InstantiationException
        void cannotInstantiateInterface() {
            assertThrows(InstantiationException.class, () -> SpnegoConstants.class.newInstance(), "Interfaces cannot be instantiated");
        }
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 3.7K bytes
    - Viewed (0)
  2. build-logic/documentation/src/test/groovy/gradlebuild/docs/XmlSpecification.groovy

    abstract class XmlSpecification extends Specification {
        final Document document = DocumentBuilderFactory.newInstance().newDocumentBuilder().newDocument()
    
        def parse(String str, Document document = null) {
            DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance()
            factory.setNamespaceAware(true)
            DocumentBuilder builder = factory.newDocumentBuilder()
    Registered: Wed Dec 31 11:36:14 UTC 2025
    - Last Modified: Wed Dec 09 08:14:05 UTC 2020
    - 4.1K bytes
    - Viewed (0)
  3. samples/guide/src/main/java/okhttp3/recipes/kt/YubikeyClientAuth.kt

        val callbackHandler = ConsoleCallbackHandler
    
        val builderList: List<KeyStore.Builder> =
          listOf(
            KeyStore.Builder.newInstance("PKCS11", null, KeyStore.CallbackHandlerProtection(callbackHandler)),
            // Example if you want to combine multiple keystore types
            // KeyStore.Builder.newInstance("PKCS12", null, File("keystore.p12"), PasswordProtection("rosebud".toCharArray()))
          )
    
    Registered: Fri Dec 26 11:42:13 UTC 2025
    - Last Modified: Sat May 10 11:15:14 UTC 2025
    - 4.2K bytes
    - Viewed (0)
  4. src/main/java/org/codelibs/core/beans/impl/ConstructorDescImpl.java

                return null;
            }
            return pcd.getRawClass();
        }
    
        @SuppressWarnings("unchecked")
        @Override
        public <T> T newInstance(final Object... args) {
            return (T) ConstructorUtil.newInstance(constructor, args);
        }
    
    Registered: Sat Dec 20 08:55:33 UTC 2025
    - Last Modified: Sat May 10 01:32:17 UTC 2025
    - 5K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/util/concurrent/CycleDetectingLockFactoryTest.java

      private ReentrantLock lock02;
      private ReentrantLock lock03;
    
      @Override
      protected void setUp() throws Exception {
        super.setUp();
        CycleDetectingLockFactory factory = CycleDetectingLockFactory.newInstance(Policies.THROW);
        lockA = factory.newReentrantLock("LockA");
        lockB = factory.newReentrantLock("LockB");
        lockC = factory.newReentrantLock("LockC");
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 16.2K bytes
    - Viewed (0)
  6. api/maven-api-xml/src/main/java/org/apache/maven/api/xml/XmlNode.java

     *
     * <p>Example usage:</p>
     * <pre>
     * XmlNode node = XmlNode.newBuilder()
     *     .name("configuration")
     *     .attribute("version", "1.0")
     *     .child(XmlNode.newInstance("property", "value"))
     *     .build();
     * </pre>
     *
     * @since 4.0.0
     */
    @Experimental
    @ThreadSafe
    @Immutable
    public interface XmlNode {
    
        /**
         * @deprecated since 4.0.0.
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Wed Dec 17 15:20:44 UTC 2025
    - 18.3K bytes
    - Viewed (0)
  7. src/main/java/jcifs/smb1/http/Handler.java

                                handlerClass = ClassLoader.getSystemClassLoader().loadClass(className);
                            }
                            handler = (URLStreamHandler) handlerClass.newInstance();
                            break;
                        } catch (final Exception ex) {}
                    }
                }
                if (handler == null) {
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 6.1K bytes
    - Viewed (0)
  8. compat/maven-model-builder/src/test/java/org/apache/maven/model/profile/activation/PropertyProfileActivatorTest.java

            props.setProperty(key, value);
            return props;
        }
    
        @Test
        void testNullSafe() throws Exception {
            Profile p = Profile.newInstance();
    
            assertActivation(false, p, newContext(null, null));
    
            p = p.withActivation(Activation.newInstance());
    
            assertActivation(false, p, newContext(null, null));
        }
    
        @Test
        void testWithNameOnlyUserProperty() throws Exception {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Fri Mar 21 04:56:21 UTC 2025
    - 5.7K bytes
    - Viewed (0)
  9. architecture/standards/0006-use-of-provider-apis-in-gradle.md

    }
    abstract class DefaultNestedType implements NestedType {
        ...
    }
    
    class Example {
        private final NestedType nested
        Example(ObjectFactory objects) {
           this.nested = objects.newInstance(DefaultNestedType.class)
        }
    
        @Nested
        NestedType getNestedProperty() {
            return nested;
        }
    }
    ```
    
    You should prefer to use managed types when possible. 
    
    Registered: Wed Dec 31 11:36:14 UTC 2025
    - Last Modified: Tue Oct 15 20:00:57 UTC 2024
    - 10K bytes
    - Viewed (0)
  10. src/test/java/org/codelibs/core/beans/impl/BeanDescImplTest.java

            assertThat((Integer) beanDesc.newInstance(10), is(10));
            assertThat((Integer) beanDesc.newInstance("10"), is(10));
        }
    
        /**
         * @throws Exception
         */
        @Test
        public void testNewInstance2() throws Exception {
            final BeanDesc beanDesc = new BeanDescImpl(Integer.class);
            assertThat((Integer) beanDesc.newInstance(new BigDecimal(10)), is(10));
        }
    
        /**
    Registered: Sat Dec 20 08:55:33 UTC 2025
    - Last Modified: Fri Jun 20 13:40:57 UTC 2025
    - 13.9K bytes
    - Viewed (0)
Back to top