Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 50 for IllegalArgumentException (0.33 sec)

  1. maven-api-impl/src/main/java/org/apache/maven/internal/impl/Utils.java

    import java.util.stream.Collectors;
    
    class Utils {
        static <T> T nonNull(T t) {
            if (t == null) {
                throw new IllegalArgumentException();
            }
            return t;
        }
    
        static <T> T nonNull(T t, String name) {
            if (t == null) {
                throw new IllegalArgumentException(name + " cannot be null");
            }
            return t;
        }
    
        static <T> T cast(Class<T> clazz, Object o, String name) {
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Fri Apr 12 10:50:18 GMT 2024
    - 1.8K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/base/Preconditions.java

       *
       * @param expression a boolean expression
       * @throws IllegalArgumentException if {@code expression} is false
       */
      public static void checkArgument(boolean expression) {
        if (!expression) {
          throw new IllegalArgumentException();
        }
      }
    
      /**
       * Ensures the truth of an expression involving one or more parameters to the calling method.
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Apr 11 11:52:14 GMT 2024
    - 52.9K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/collect/ImmutableBiMap.java

       * Entries appear in the result {@code ImmutableBiMap} in encounter order.
       *
       * <p>If the mapped keys or values contain duplicates (according to {@link
       * Object#equals(Object)}), an {@code IllegalArgumentException} is thrown when the collection
       * operation is performed. (This differs from the {@code Collector} returned by {@link
       * Collectors#toMap(Function, Function)}, which throws an {@code IllegalStateException}.)
       *
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 22.4K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/MoreCollectors.java

              ToOptionalState::getOptional,
              Collector.Characteristics.UNORDERED);
    
      /**
       * A collector that converts a stream of zero or one elements to an {@code Optional}.
       *
       * @throws IllegalArgumentException if the stream consists of two or more elements.
       * @throws NullPointerException if any element in the stream is {@code null}.
       * @return {@code Optional.of(onlyElement)} if the stream has exactly one element (must not be
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 5.7K bytes
    - Viewed (0)
  5. maven-api-impl/src/main/java/org/apache/maven/internal/impl/DefaultTransport.java

            if (relativeSource.isAbsolute()) {
                throw new IllegalArgumentException("Supplied URI is not relative");
            }
            URI source = baseURI.resolve(relativeSource);
            if (!source.toASCIIString().startsWith(baseURI.toASCIIString())) {
                throw new IllegalArgumentException("Supplied relative URI escapes baseUrl");
            }
            GetTask getTask = new GetTask(source);
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Thu May 02 16:33:18 GMT 2024
    - 5.3K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/ImmutableMap.java

        if (!safe) {
          throw conflictException(conflictDescription, entry1, entry2);
        }
      }
    
      static IllegalArgumentException conflictException(
          String conflictDescription, Object entry1, Object entry2) {
        return new IllegalArgumentException(
            "Multiple entries with same " + conflictDescription + ": " + entry1 + " and " + entry2);
      }
    
      /**
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 41.7K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/ImmutableSortedMap.java

       * elements. The generated map is sorted by the specified comparator.
       *
       * <p>If the mapped keys contain duplicates (according to the specified comparator), an {@code
       * IllegalArgumentException} is thrown when the collection operation is performed. (This differs
       * from the {@code Collector} returned by {@link Collectors#toMap(Function, Function)}, which
       * throws an {@code IllegalStateException}.)
       *
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 53.2K bytes
    - Viewed (0)
  8. maven-api-impl/src/main/java/org/apache/maven/internal/impl/resolver/relocation/UserPropertiesArtifactRelocationSource.java

                            } else {
                                throw new IllegalArgumentException("Unrecognized entry: " + l);
                            }
                            String[] parts = l.split(splitExpr);
                            if (parts.length < 1) {
                                throw new IllegalArgumentException("Unrecognized entry: " + l);
                            }
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Fri Apr 12 10:50:18 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/ImmutableRangeSet.java

          // the range have a lower bound
          throw new IllegalArgumentException(
              "Neither the DiscreteDomain nor this range set are bounded below");
        } else if (!span.hasUpperBound()) {
          try {
            domain.maxValue();
          } catch (NoSuchElementException e) {
            throw new IllegalArgumentException(
                "Neither the DiscreteDomain nor this range set are bounded above");
          }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 27.2K bytes
    - Viewed (0)
  10. maven-api-impl/src/main/java/org/apache/maven/internal/impl/DefaultModelXmlFactory.java

            Reader reader = request.getReader();
            InputStream inputStream = request.getInputStream();
            if (path == null && url == null && reader == null && inputStream == null) {
                throw new IllegalArgumentException("path, url, reader or inputStream must be non null");
            }
            try {
                InputSource source = null;
                if (request.getModelId() != null || request.getLocation() != null) {
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Fri Apr 12 10:50:18 GMT 2024
    - 5.4K bytes
    - Viewed (0)
Back to top