Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 199 for collectionize (0.16 sec)

  1. platforms/core-runtime/base-services/src/test/groovy/org/gradle/util/internal/GUtilTest.groovy

        def "normalizes to collection"() {
            expect:
            collectionize(null) == []
            collectionize(10) == [10]
            collectionize("a") == ["a"]
    
            List list = [2, 2, "three"] as List
            collectionize(list) == [2, 2, "three"]
    
            Object[] array = [1, 1, "three"]
            collectionize(array) == [1, 1, "three"]
    
            collectionize([list, array]) == [2, 2, "three", 1, 1, "three"]
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Sep 22 08:48:02 UTC 2023
    - 9.7K bytes
    - Viewed (0)
  2. platforms/core-runtime/base-services/src/main/java/org/gradle/util/internal/GUtil.java

         *
         * @param input any object
         * @return collection of flattened input or single input wrapped in a collection.
         */
        @SuppressWarnings("MixedMutabilityReturnType")
        public static Collection<?> collectionize(Object input) {
            if (input == null) {
                return emptyList();
            } else if (input instanceof Collection) {
                Collection<?> out = new LinkedList<Object>();
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed May 29 06:47:40 UTC 2024
    - 19.3K bytes
    - Viewed (0)
  3. platforms/core-runtime/logging/src/main/java/org/gradle/util/GUtil.java

         *
         * @param input any object
         * @return collection of flattened input or single input wrapped in a collection.
         */
        @SuppressWarnings("MixedMutabilityReturnType")
        public static Collection<?> collectionize(Object input) {
            if (input == null) {
                return emptyList();
            } else if (input instanceof Collection) {
                Collection<?> out = new LinkedList<Object>();
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue May 28 13:09:37 UTC 2024
    - 21.3K bytes
    - Viewed (0)
  4. android/guava-testlib/src/com/google/common/collect/testing/features/CollectionSize.java

     * Note that this means a test should not require more than one CollectionSize, since a particular
     * collection instance can only be one size at once.
     *
     * @author George van den Driessche
     */
    @SuppressWarnings("rawtypes") // maybe avoidable if we rework the whole package?
    @GwtCompatible
    public enum CollectionSize implements Feature<Collection>, Comparable<CollectionSize> {
      /** Test an empty collection. */
      ZERO(0),
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Feb 26 19:46:10 UTC 2024
    - 3.4K bytes
    - Viewed (0)
  5. guava-testlib/src/com/google/common/collect/testing/features/CollectionSize.java

     * Note that this means a test should not require more than one CollectionSize, since a particular
     * collection instance can only be one size at once.
     *
     * @author George van den Driessche
     */
    @SuppressWarnings("rawtypes") // maybe avoidable if we rework the whole package?
    @GwtCompatible
    public enum CollectionSize implements Feature<Collection>, Comparable<CollectionSize> {
      /** Test an empty collection. */
      ZERO(0),
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Feb 26 19:46:10 UTC 2024
    - 3.4K bytes
    - Viewed (0)
  6. guava-testlib/src/com/google/common/collect/testing/PerCollectionSizeTestSuiteBuilder.java

        // Split out all the specified sizes.
        Set<Feature<?>> sizesToTest = Helpers.<Feature<?>>copyToSet(CollectionSize.values());
        sizesToTest.retainAll(features);
        features.removeAll(sizesToTest);
    
        FeatureUtil.addImpliedFeatures(sizesToTest);
        sizesToTest.retainAll(
            Arrays.asList(CollectionSize.ZERO, CollectionSize.ONE, CollectionSize.SEVERAL));
    
        logger.fine("   Sizes: " + formatFeatureSet(sizesToTest));
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Feb 26 19:46:10 UTC 2024
    - 5.3K bytes
    - Viewed (0)
  7. android/guava-testlib/src/com/google/common/collect/testing/PerCollectionSizeTestSuiteBuilder.java

        // Split out all the specified sizes.
        Set<Feature<?>> sizesToTest = Helpers.<Feature<?>>copyToSet(CollectionSize.values());
        sizesToTest.retainAll(features);
        features.removeAll(sizesToTest);
    
        FeatureUtil.addImpliedFeatures(sizesToTest);
        sizesToTest.retainAll(
            Arrays.asList(CollectionSize.ZERO, CollectionSize.ONE, CollectionSize.SEVERAL));
    
        logger.fine("   Sizes: " + formatFeatureSet(sizesToTest));
    
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Mon Feb 26 19:46:10 UTC 2024
    - 5.3K bytes
    - Viewed (0)
  8. android/guava-testlib/src/com/google/common/collect/testing/testers/CollectionRetainAllTester.java

    import static com.google.common.collect.testing.features.CollectionFeature.SUPPORTS_REMOVE;
    import static com.google.common.collect.testing.features.CollectionSize.ONE;
    import static com.google.common.collect.testing.features.CollectionSize.ZERO;
    
    import com.google.common.annotations.GwtCompatible;
    import com.google.common.collect.testing.AbstractCollectionTester;
    import com.google.common.collect.testing.MinimalCollection;
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Feb 20 17:00:05 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  9. guava-testlib/src/com/google/common/collect/testing/testers/SortedSetNavigationTester.java

    import static com.google.common.collect.testing.features.CollectionSize.ONE;
    import static com.google.common.collect.testing.features.CollectionSize.SEVERAL;
    import static com.google.common.collect.testing.features.CollectionSize.ZERO;
    
    import com.google.common.annotations.GwtCompatible;
    import com.google.common.collect.testing.Helpers;
    import com.google.common.collect.testing.features.CollectionSize;
    import java.util.Collections;
    import java.util.List;
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 21 16:49:06 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  10. guava-testlib/src/com/google/common/collect/testing/google/BiMapPutTester.java

     */
    
    package com.google.common.collect.testing.google;
    
    import static com.google.common.collect.testing.features.CollectionSize.ONE;
    import static com.google.common.collect.testing.features.CollectionSize.SEVERAL;
    import static com.google.common.collect.testing.features.CollectionSize.ZERO;
    import static com.google.common.collect.testing.features.MapFeature.ALLOWS_NULL_KEYS;
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Feb 20 17:00:05 UTC 2024
    - 4.9K bytes
    - Viewed (0)
Back to top