Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for Truncate (0.16 sec)

  1. android/guava-tests/test/com/google/common/base/AsciiTest.java

        assertEquals("foobar", Ascii.truncate("foobar", 6, "…"));
        assertEquals("foob…", Ascii.truncate("foobar", 5, "…"));
        assertEquals("foo", Ascii.truncate("foobar", 3, ""));
        assertEquals("", Ascii.truncate("", 5, ""));
        assertEquals("", Ascii.truncate("", 5, "..."));
        assertEquals("", Ascii.truncate("", 0, ""));
      }
    
      public void testTruncateIllegalArguments() {
        try {
          Ascii.truncate("foobar", 2, "...");
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri Feb 09 15:49:48 GMT 2024
    - 5.5K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/base/AsciiTest.java

        assertEquals("foobar", Ascii.truncate("foobar", 6, "…"));
        assertEquals("foob…", Ascii.truncate("foobar", 5, "…"));
        assertEquals("foo", Ascii.truncate("foobar", 3, ""));
        assertEquals("", Ascii.truncate("", 5, ""));
        assertEquals("", Ascii.truncate("", 5, "..."));
        assertEquals("", Ascii.truncate("", 0, ""));
      }
    
      public void testTruncateIllegalArguments() {
        try {
          Ascii.truncate("foobar", 2, "...");
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Fri Feb 09 15:49:48 GMT 2024
    - 5.5K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/collect/StreamsTest.java

            .containsExactly("a:1", "b:2", "c:3")
            .inOrder();
      }
    
      public void testZipInfiniteWithInfinite() {
        // zip is doing an infinite zip, but we truncate the result so we can actually test it
        // but we want the zip itself to work
        assertThat(
                Streams.zip(
                        Stream.iterate(1, i -> i + 1).map(String::valueOf),
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 20K bytes
    - Viewed (0)
  4. maven-compat/src/main/java/org/apache/maven/repository/legacy/DefaultUpdateCheckManager.java

                    } else {
                        props.remove(key + ERROR_KEY_SUFFIX);
                    }
    
                    getLogger().debug("Writing resolution-state to: " + touchfile);
                    channel.truncate(0);
                    props.store(Channels.newOutputStream(channel), "Last modified on: " + new Date());
    
                    lock.release();
                    lock = null;
    
                    channel.close();
    Java
    - Registered: Sun May 05 03:35:11 GMT 2024
    - Last Modified: Wed Sep 06 11:28:54 GMT 2023
    - 12.1K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/collect/ImmutableMapTest.java

      public void testBuildKeepingLast_shortTable() {
        Builder<Integer, String> builder = ImmutableMap.builder();
        Map<Integer, String> expected = new LinkedHashMap<>();
        for (int i = 0; i < 1000; i++) {
          // Truncate to even key, so we have put(0, "0") then put(0, "1"). Half the entries are
          // duplicates.
          Integer key = i & ~1;
          String value = String.valueOf(i);
          builder.put(key, value);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Apr 30 14:39:16 GMT 2024
    - 37.3K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/collect/ImmutableMapTest.java

      public void testBuildKeepingLast_shortTable() {
        Builder<Integer, String> builder = ImmutableMap.builder();
        Map<Integer, String> expected = new LinkedHashMap<>();
        for (int i = 0; i < 1000; i++) {
          // Truncate to even key, so we have put(0, "0") then put(0, "1"). Half the entries are
          // duplicates.
          Integer key = i & ~1;
          String value = String.valueOf(i);
          builder.put(key, value);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Feb 27 13:27:08 GMT 2024
    - 41.3K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

          }
        }
    
        // The future may complete while calculating the toString, so we check once more to see if the
        // future is done
        if (isDone()) {
          // Truncate anything that was appended before realizing this future is done
          builder.delete(truncateLength, builder.length());
          addDoneString(builder);
        }
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 63K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/CycleDetectingLockFactory.java

            }
          };
    
      /**
       * A Throwable used to record a stack trace that illustrates an example of a specific lock
       * acquisition ordering. The top of the stack trace is truncated such that it starts with the
       * acquisition of the lock in question, e.g.
       *
       * <pre>
       * com...ExampleStackTrace: LockB -&gt; LockC
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Dec 15 19:31:54 GMT 2023
    - 35.9K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/collect/Multisets.java

              }
            };
          }
        };
      }
    
      /**
       * Returns an unmodifiable view of the difference of two multisets. In the returned multiset, the
       * count of each element is the result of the <i>zero-truncated subtraction</i> of its count in
       * the second multiset from its count in the first multiset, with elements that would have a count
       * of 0 not included. The iteration order of the returned multiset matches that of the element set
    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)
  10. android/guava/src/com/google/common/collect/TreeRangeMap.java

                  rangeToRemove.upperBound,
                  rangeMapEntry.getUpperBound(),
                  mapEntryBelowToTruncate.getValue().getValue());
            }
            // overwrite mapEntryToTruncateBelow with a truncated range
            putRangeMapEntry(
                rangeMapEntry.getLowerBound(),
                rangeToRemove.lowerBound,
                mapEntryBelowToTruncate.getValue().getValue());
          }
        }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 21.9K bytes
    - Viewed (0)
Back to top