Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,170 for throw (0.25 sec)

  1. android/guava-tests/test/com/google/common/collect/AbstractIteratorTest.java

        } catch (Exception e) {
          if (!(e instanceof SomeCheckedException)) {
            throw e;
          }
        }
    
        // But the second time, AbstractIterator itself throws an ISE
        try {
          iter.hasNext();
          fail("No exception thrown");
        } catch (IllegalStateException expected) {
        }
      }
    
      public void testException() {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 10:16:44 GMT 2024
    - 8.7K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/base/AbstractIteratorTest.java

                  sneakyThrow(new SomeCheckedException());
                  throw new AssertionError(); // unreachable
                }
              }
            };
    
        // The first time, the sneakily-thrown exception comes out
        try {
          iter.hasNext();
          fail("No exception thrown");
        } catch (Exception e) {
          if (!(e instanceof SomeCheckedException)) {
            throw e;
          }
        }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu May 04 09:41:29 GMT 2023
    - 6.1K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/base/AbstractIteratorTest.java

                  sneakyThrow(new SomeCheckedException());
                  throw new AssertionError(); // unreachable
                }
              }
            };
    
        // The first time, the sneakily-thrown exception comes out
        try {
          iter.hasNext();
          fail("No exception thrown");
        } catch (Exception e) {
          if (!(e instanceof SomeCheckedException)) {
            throw e;
          }
        }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu May 04 09:41:29 GMT 2023
    - 6.1K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/eventbus/SubscriberTest.java

      public void exceptionThrowingMethod(Object arg) throws Exception {
        throw new IntentionalException();
      }
    
      /** Local exception subclass to check variety of exception thrown. */
      class IntentionalException extends Exception {
    
        private static final long serialVersionUID = -2500191180248181379L;
      }
    
      @Subscribe
      public void errorThrowingMethod(Object arg) {
        throw new JudgmentError();
      }
    
      @Subscribe
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.8K bytes
    - Viewed (0)
  5. guava-testlib/src/com/google/common/testing/ForwardingWrapperTester.java

                      throws Throwable {
                    throw exception;
                  }
                });
        T wrapper = wrapperFunction.apply(proxy);
        try {
          method.invoke(wrapper, getParameterValues(method));
          fail(method + " failed to throw exception as is.");
        } catch (InvocationTargetException e) {
          if (exception != e.getCause()) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Feb 08 17:31:55 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/testing/ForwardingWrapperTester.java

                      throws Throwable {
                    throw exception;
                  }
                });
        T wrapper = wrapperFunction.apply(proxy);
        try {
          method.invoke(wrapper, getParameterValues(method));
          fail(method + " failed to throw exception as is.");
        } catch (InvocationTargetException e) {
          if (exception != e.getCause()) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 08 17:31:55 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  7. maven-core/src/main/java/org/apache/maven/internal/impl/DefaultToolchainsXmlFactory.java

        @Override
        public PersistedToolchains read(@Nonnull XmlReaderRequest request) throws XmlReaderException {
            Objects.requireNonNull(request, "request");
            Reader reader = request.getReader();
            InputStream inputStream = request.getInputStream();
            if (reader == null && inputStream == null) {
                throw new IllegalArgumentException("reader or inputStream must be non null");
            }
            try {
    Java
    - Registered: Sun Mar 24 03:35:10 GMT 2024
    - Last Modified: Thu Dec 07 20:05:02 GMT 2023
    - 3.7K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/cache/AbstractLoadingCacheTest.java

        LoadingCache<Object, Object> cache =
            new AbstractLoadingCache<Object, Object>() {
              @Override
              public Object get(Object key) throws ExecutionException {
                Object v = valueRef.get();
                if (v == null) {
                  throw new ExecutionException(cause);
                }
                return v;
              }
    
              @Override
              public @Nullable Object getIfPresent(Object key) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 5K bytes
    - Viewed (0)
  9. maven-api-impl/src/main/java/org/apache/maven/internal/impl/DefaultToolchainsXmlFactory.java

        @Override
        public PersistedToolchains read(@Nonnull XmlReaderRequest request) throws XmlReaderException {
            Objects.requireNonNull(request, "request");
            Reader reader = request.getReader();
            InputStream inputStream = request.getInputStream();
            if (reader == null && inputStream == null) {
                throw new IllegalArgumentException("reader or inputStream must be non null");
            }
            try {
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Mon Mar 25 10:50:01 GMT 2024
    - 3.9K bytes
    - Viewed (0)
  10. src/main/java/jcifs/spnego/NegTokenInit.java

                    throw new IOException("Malformed SPNEGO token " + constructed);
    
                ASN1Sequence vec = (ASN1Sequence) constructed.getBaseObject();
    
    
                    ASN1ObjectIdentifier spnego = (ASN1ObjectIdentifier) vec.getObjectAt(0);
                    if ( !SPNEGO_OID.equals(spnego) ) {
                        throw new IOException("Malformed SPNEGO token, OID " + spnego);
    Java
    - Registered: Sun May 05 00:10:10 GMT 2024
    - Last Modified: Sun Oct 01 12:01:17 GMT 2023
    - 7.9K bytes
    - Viewed (0)
Back to top