Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 61 - 70 of 167 for newInstance (0.06 seconds)

  1. 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");
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Mar 16 22:45:21 GMT 2026
    - 16.3K bytes
    - Click Count (0)
  2. 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) {
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 16 01:32:48 GMT 2025
    - 6.1K bytes
    - Click Count (0)
  3. 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 {
    Created: Sun Apr 05 03:35:12 GMT 2026
    - Last Modified: Fri Mar 21 04:56:21 GMT 2025
    - 5.7K bytes
    - Click Count (0)
  4. android/guava/src/com/google/common/util/concurrent/CycleDetectingLockFactory.java

          @Override
          public void handlePotentialDeadlock(PotentialDeadlockException e) {}
        };
      }
    
      /** Creates a new factory with the specified policy. */
      public static CycleDetectingLockFactory newInstance(Policy policy) {
        return new CycleDetectingLockFactory(policy);
      }
    
      /** Equivalent to {@code newReentrantLock(lockName, false)}. */
      public ReentrantLock newReentrantLock(String lockName) {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Wed Apr 01 17:27:13 GMT 2026
    - 36K bytes
    - Click Count (0)
  5. guava/src/com/google/common/collect/ObjectArrays.java

       *
       * @param type the component type
       * @param length the length of the new array
       */
      @GwtIncompatible // Array.newInstance(Class, int)
      @SuppressWarnings("unchecked")
      public static <T extends @Nullable Object> T[] newArray(Class<@NonNull T> type, int length) {
        return (T[]) Array.newInstance(type, length);
      }
    
      /**
       * Returns a new array of the given length with the same type as a reference array.
       *
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Fri Jan 23 17:16:53 GMT 2026
    - 9.2K bytes
    - Click Count (0)
  6. compat/maven-resolver-provider/src/main/java/org/apache/maven/repository/internal/DefaultModelCacheFactory.java

    @Named
    @Deprecated(since = "4.0.0")
    public class DefaultModelCacheFactory implements ModelCacheFactory {
        @Override
        public ModelCache createCache(RepositorySystemSession session) {
            return DefaultModelCache.newInstance(session);
        }
    Created: Sun Apr 05 03:35:12 GMT 2026
    - Last Modified: Fri Oct 25 12:31:46 GMT 2024
    - 1.4K bytes
    - Click Count (0)
  7. api/maven-api-settings/src/test/java/org/apache/maven/api/settings/SettingsTest.java

    import static org.junit.jupiter.api.Assertions.assertEquals;
    import static org.junit.jupiter.api.Assertions.assertNull;
    
    class SettingsTest {
    
        @Test
        void testSetLocalRepository() {
            Settings s = Settings.newInstance();
    
            s = s.withLocalRepository("xxx");
            assertEquals("xxx", s.getLocalRepository());
    
            s = s.withLocalRepository("yyy");
            assertEquals("yyy", s.getLocalRepository());
    
    Created: Sun Apr 05 03:35:12 GMT 2026
    - Last Modified: Sat Apr 15 17:24:20 GMT 2023
    - 1.4K bytes
    - Click Count (0)
  8. impl/maven-core/src/main/java/org/apache/maven/lifecycle/internal/DefaultLifecycleExecutionPlanCalculator.java

                    ? mojoExecution.getConfiguration().getDom()
                    : null;
            if (executionConfiguration == null) {
                executionConfiguration = XmlNode.newInstance("configuration");
            }
    
            XmlNode defaultConfiguration = getMojoConfiguration(mojoDescriptor);
    
            List<XmlNode> children = new ArrayList<>();
            if (mojoDescriptor.getParameters() != null) {
    Created: Sun Apr 05 03:35:12 GMT 2026
    - Last Modified: Tue Mar 25 09:45:07 GMT 2025
    - 26.7K bytes
    - Click Count (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. 
    
    Created: Wed Apr 01 11:36:16 GMT 2026
    - Last Modified: Thu Mar 05 12:39:41 GMT 2026
    - 10K bytes
    - Click Count (0)
  10. src/main/java/jcifs/http/Handler.java

                                handlerClass = ClassLoader.getSystemClassLoader().loadClass(className);
                            }
                            handler = (URLStreamHandler) handlerClass.newInstance();
                            break;
                        } catch (final Exception ex) {
                            log.debug("Failed to initialize handler " + className, ex);
                        }
                    }
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 16 01:32:48 GMT 2025
    - 6.9K bytes
    - Click Count (0)
Back to Top