Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for UnicodeEscaper (0.08 sec)

  1. android/guava/src/com/google/common/escape/UnicodeEscaper.java

     * characters.
     *
     * <p>As there are important reasons, including potential security issues, to handle Unicode
     * correctly if you are considering implementing a new escaper you should favor using UnicodeEscaper
     * wherever possible.
     *
     * <p>A {@code UnicodeEscaper} instance is required to be stateless, and safe when used concurrently
     * by multiple threads.
     *
     * <p>Popular escapers are defined as constants in classes like {@link
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Jan 18 20:55:09 UTC 2022
    - 13.2K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/net/UrlEscaperTesting.java

      }
    
      // Helper to assert common expected behaviour of uri escapers.
      static void assertBasicUrlEscaper(UnicodeEscaper e) {
        assertBasicUrlEscaperExceptPercent(e);
        // The escape character must always be escaped
        assertEscaping(e, "%25", '%');
      }
    
      static void assertPathEscaper(UnicodeEscaper e) {
        assertBasicUrlEscaper(e);
    
        assertUnescaped(e, '!');
        assertUnescaped(e, '\'');
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 17:53:22 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/net/UrlEscapersTest.java

        assertEquals("foo%40bar.com", e.escape("******@****.***"));
      }
    
      public void testUrlPathSegmentEscaper() {
        UnicodeEscaper e = (UnicodeEscaper) urlPathSegmentEscaper();
        assertPathEscaper(e);
        assertUnescaped(e, '+');
      }
    
      public void testUrlFragmentEscaper() {
        UnicodeEscaper e = (UnicodeEscaper) urlFragmentEscaper();
        assertUnescaped(e, '+');
        assertUnescaped(e, '/');
        assertUnescaped(e, '?');
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 17:53:22 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/net/PercentEscaperTest.java

      }
    
      /** Tests the various ways that the space character can be handled */
      public void testPlusForSpace() {
        UnicodeEscaper basicEscaper = new PercentEscaper("", false);
        UnicodeEscaper plusForSpaceEscaper = new PercentEscaper("", true);
        UnicodeEscaper spaceEscaper = new PercentEscaper(" ", false);
    
        assertEquals("string%20with%20spaces", basicEscaper.escape("string with spaces"));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 15:41:36 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/escape/UnicodeEscaperTest.java

      // Escapes nothing
      private static final UnicodeEscaper NOP_ESCAPER =
          new UnicodeEscaper() {
            @Override
            protected char @Nullable [] escape(int c) {
              return null;
            }
          };
    
      // Escapes everything except [a-zA-Z0-9]
      private static final UnicodeEscaper SIMPLE_ESCAPER =
          new UnicodeEscaper() {
            @Override
            protected char @Nullable [] escape(int cp) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 15:00:32 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/escape/UnicodeEscaperTest.java

      // Escapes nothing
      private static final UnicodeEscaper NOP_ESCAPER =
          new UnicodeEscaper() {
            @Override
            protected char @Nullable [] escape(int c) {
              return null;
            }
          };
    
      // Escapes everything except [a-zA-Z0-9]
      private static final UnicodeEscaper SIMPLE_ESCAPER =
          new UnicodeEscaper() {
            @Override
            protected char @Nullable [] escape(int cp) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 15:00:32 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/net/UrlEscapersTest.java

        assertEquals("foo%40bar.com", e.escape("******@****.***"));
      }
    
      public void testUrlPathSegmentEscaper() {
        UnicodeEscaper e = (UnicodeEscaper) urlPathSegmentEscaper();
        assertPathEscaper(e);
        assertUnescaped(e, '+');
      }
    
      public void testUrlFragmentEscaper() {
        UnicodeEscaper e = (UnicodeEscaper) urlFragmentEscaper();
        assertUnescaped(e, '+');
        assertUnescaped(e, '/');
        assertUnescaped(e, '?');
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 17:53:22 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/net/UrlEscaperTesting.java

      }
    
      // Helper to assert common expected behaviour of uri escapers.
      static void assertBasicUrlEscaper(UnicodeEscaper e) {
        assertBasicUrlEscaperExceptPercent(e);
        // The escape character must always be escaped
        assertEscaping(e, "%25", '%');
      }
    
      static void assertPathEscaper(UnicodeEscaper e) {
        assertBasicUrlEscaper(e);
    
        assertUnescaped(e, '!');
        assertUnescaped(e, '\'');
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 17:53:22 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/net/PercentEscaperTest.java

      }
    
      /** Tests the various ways that the space character can be handled */
      public void testPlusForSpace() {
        UnicodeEscaper basicEscaper = new PercentEscaper("", false);
        UnicodeEscaper plusForSpaceEscaper = new PercentEscaper("", true);
        UnicodeEscaper spaceEscaper = new PercentEscaper(" ", false);
    
        assertEquals("string%20with%20spaces", basicEscaper.escape("string with spaces"));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 15:41:36 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  10. guava-testlib/src/com/google/common/escape/testing/EscaperAsserts.java

    import com.google.common.annotations.GwtCompatible;
    import com.google.common.escape.CharEscaper;
    import com.google.common.escape.Escaper;
    import com.google.common.escape.UnicodeEscaper;
    import java.io.IOException;
    import junit.framework.Assert;
    
    /**
     * Extra assert methods for testing Escaper implementations.
     *
     * @author David Beaumont
     * @since 15.0
     */
    @GwtCompatible
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Jan 18 20:55:09 UTC 2022
    - 3.8K bytes
    - Viewed (0)
Back to top