Search Options

Results per page
Sort
Preferred Languages
Advance

Results 191 - 200 of 269 for IllegalStateException (0.07 sec)

  1. okhttp/src/jvmTest/kotlin/okhttp3/MultipartBodyTest.kt

    import okio.Buffer
    import okio.BufferedSink
    import okio.utf8Size
    import org.junit.jupiter.api.Test
    
    class MultipartBodyTest {
      @Test
      fun onePartRequired() {
        assertFailsWith<IllegalStateException> {
          MultipartBody.Builder().build()
        }.also { expected ->
          assertThat(expected.message)
            .isEqualTo("Multipart body must have at least one part.")
        }
      }
    
      @Test
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 10.5K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/hash/HashCodeTest.java

        assertEquals(expectedHashCode.asInt, hash.asInt());
        if (expectedHashCode.asLong == null) {
          try {
            hash.asLong();
            fail();
          } catch (IllegalStateException expected) {
          }
        } else {
          assertEquals(expectedHashCode.asLong.longValue(), hash.asLong());
        }
        assertEquals(expectedHashCode.toString, hash.toString());
        assertSideEffectFree(hash);
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Sun Dec 22 03:38:46 UTC 2024
    - 13.1K bytes
    - Viewed (0)
  3. api/maven-api-core/src/main/java/org/apache/maven/api/services/ProblemCollector.java

                    return 0;
                }
    
                @Override
                public boolean reportProblem(P problem) {
                    throw new IllegalStateException("empty problem collector");
                }
    
                @Override
                public Stream<P> problems(BuilderProblem.Severity severity) {
                    return Stream.empty();
                }
            };
    Registered: Sun Sep 07 03:35:12 UTC 2025
    - Last Modified: Fri Jul 18 17:30:19 UTC 2025
    - 11.4K bytes
    - Viewed (0)
  4. src/test/java/jcifs/smb1/util/HMACT64Test.java

            hmac.engineUpdate(TEST_DATA, 0, TEST_DATA.length);
    
            byte[] buffer = new byte[10];
            // Should throw exception when buffer is too small
            assertThrows(IllegalStateException.class, () -> hmac.engineDigest(buffer, 0, 10));
        }
    
        @Test
        void testClone() {
            // Test clone() method
            HMACT64 originalHmac = new HMACT64(TEST_KEY);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 10.1K bytes
    - Viewed (0)
  5. api/maven-api-toolchain/src/main/mdo/toolchains.mdo

            private String sourceLevel = USER_LEVEL;
            private boolean sourceLevelSet = false;
    
            public void setSourceLevel(String sourceLevel) {
                if (sourceLevelSet) {
                    throw new IllegalStateException("Cannot reset sourceLevel attribute; it is already set to: " + sourceLevel);
                } else if (!(USER_LEVEL.equals(sourceLevel) || GLOBAL_LEVEL.equals(sourceLevel))) {
    Registered: Sun Sep 07 03:35:12 UTC 2025
    - Last Modified: Sun May 18 09:15:56 UTC 2025
    - 9.5K bytes
    - Viewed (0)
  6. src/main/java/jcifs/util/ResourceManager.java

                this.resource = resource;
                this.resourceId = resourceId;
                this.manager = manager;
            }
    
            public T get() {
                if (closed) {
                    throw new IllegalStateException("Resource has been closed: " + resourceId);
                }
                return resource;
            }
    
            @Override
            public void close() throws Exception {
                if (closed) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 16.2K bytes
    - Viewed (0)
  7. src/main/java/jcifs/util/AuthenticationRateLimiter.java

         * @throws SmbException if account is locked out
         */
        public boolean checkAttempt(String username, String sourceIp) throws SmbException {
            if (closed.get()) {
                throw new IllegalStateException("Rate limiter is closed");
            }
    
            // Check global rate limit
            if (!checkGlobalRateLimit()) {
                totalAttemptsBlocked.incrementAndGet();
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 15.1K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/collect/TableCollectorsTest.java

            TableCollectors.toTable(
                Cell::getRowKey, Cell::getColumnKey, Cell::getValue, HashBasedTable::create);
        assertThrows(
            IllegalStateException.class,
            () ->
                Stream.of(immutableCell("one", "uno", 1), immutableCell("one", "uno", 2))
                    .collect(collector));
      }
    
      public void testToTableMerging() {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Aug 07 16:05:33 UTC 2025
    - 12.5K bytes
    - Viewed (0)
  9. src/test/java/org/codelibs/core/beans/impl/BeanDescImplTest.java

             */
            public Integer echo(final Integer arg) {
                return arg;
            }
    
            /**
             *
             */
            public void throwException() {
                throw new IllegalStateException("hoge");
            }
        }
    
        /**
         *
         */
        public class MyBean2 {
            /**
             *
             */
            public MyBean2() {
            }
    
            /**
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Fri Jun 20 13:40:57 UTC 2025
    - 13.9K bytes
    - Viewed (0)
  10. guava/src/com/google/common/net/MediaType.java

        return Maps.transformValues(parameters.asMap(), ImmutableMultiset::copyOf);
      }
    
      /**
       * Returns an optional charset for the value of the charset parameter if it is specified.
       *
       * @throws IllegalStateException if multiple charset values have been set for this media type
       * @throws IllegalCharsetNameException if a charset value is present, but illegal
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Tue May 13 17:27:14 UTC 2025
    - 48K bytes
    - Viewed (0)
Back to top