Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 11 - 20 of 45 for Escapers (0.04 seconds)

  1. android/guava/src/com/google/common/escape/package-info.java

     * the License.
     */
    
    /**
     * Interfaces, utilities, and simple implementations of escapers and encoders. The primary type is
     * {@link Escaper}.
     *
     * <p>Additional escapers implementations are found in the applicable packages: {@link
     * com.google.common.html.HtmlEscapers} in {@code com.google.common.html}, {@link
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sat Dec 21 14:50:24 GMT 2024
    - 1.3K bytes
    - Click Count (0)
  2. android/guava-testlib/src/com/google/common/escape/testing/EscaperAsserts.java

      private EscaperAsserts() {}
    
      /**
       * Asserts that an escaper behaves correctly with respect to null inputs.
       *
       * @param escaper the non-null escaper to test
       */
      public static void assertBasic(Escaper escaper) throws IOException {
        // Escapers operate on characters: no characters, no escaping.
        Assert.assertEquals("", escaper.escape(""));
        // Assert that escapers throw null pointer exceptions.
        try {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Jan 18 20:55:09 GMT 2022
    - 3.8K bytes
    - Click Count (0)
  3. guava-testlib/src/com/google/common/escape/testing/EscaperAsserts.java

      private EscaperAsserts() {}
    
      /**
       * Asserts that an escaper behaves correctly with respect to null inputs.
       *
       * @param escaper the non-null escaper to test
       */
      public static void assertBasic(Escaper escaper) throws IOException {
        // Escapers operate on characters: no characters, no escaping.
        Assert.assertEquals("", escaper.escape(""));
        // Assert that escapers throw null pointer exceptions.
        try {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Jan 18 20:55:09 GMT 2022
    - 3.8K bytes
    - Click Count (0)
  4. android/guava/src/com/google/common/escape/CharEscaper.java

     *
     * <p>A {@code CharEscaper} 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
     * com.google.common.html.HtmlEscapers} and {@link com.google.common.xml.XmlEscapers}. To create
     * your own escapers extend this class and implement the {@link #escape(char)} method.
     *
     * @author Sven Mawson
     * @since 15.0
     */
    @GwtCompatible
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Feb 13 15:45:16 GMT 2025
    - 6.7K bytes
    - Click Count (0)
  5. android/guava/src/com/google/common/html/package-info.java

     * or implied. See the License for the specific language governing permissions and limitations under
     * the License.
     */
    
    /**
     * Escapers
     * for
     * HTML.
     *
     * <p>This package is a part of the open-source <a href="https://github.com/google/guava">Guava</a>
     * library.
     */
    @CheckReturnValue
    @NullMarked
    package com.google.common.html;
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sat Dec 21 14:50:24 GMT 2024
    - 913 bytes
    - Click Count (0)
  6. guava-tests/test/com/google/common/xml/XmlEscapersTest.java

        // Test all escapes
        assertThat(xmlAttributeEscaper.escape("a\"b<c>d&e\"f'"))
            .isEqualTo("a&quot;b&lt;c&gt;d&amp;e&quot;f&apos;");
        // Test '\t', '\n' and '\r' are escaped.
        assertThat(xmlAttributeEscaper.escape("a\tb\nc\rd")).isEqualTo("a&#x9;b&#xA;c&#xD;d");
      }
    
      // Helper to assert common properties of xml escapers.
      static void assertBasicXmlEscaper(
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 12 17:47:10 GMT 2026
    - 5K bytes
    - Click Count (0)
  7. android/guava-tests/test/com/google/common/xml/XmlEscapersTest.java

        // Test all escapes
        assertThat(xmlAttributeEscaper.escape("a\"b<c>d&e\"f'"))
            .isEqualTo("a&quot;b&lt;c&gt;d&amp;e&quot;f&apos;");
        // Test '\t', '\n' and '\r' are escaped.
        assertThat(xmlAttributeEscaper.escape("a\tb\nc\rd")).isEqualTo("a&#x9;b&#xA;c&#xD;d");
      }
    
      // Helper to assert common properties of xml escapers.
      static void assertBasicXmlEscaper(
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 12 17:47:10 GMT 2026
    - 5K bytes
    - Click Count (0)
  8. guava-tests/test/com/google/common/escape/ArrayBasedUnicodeEscaperTest.java

              }
            };
        EscaperAsserts.assertBasic(escaper);
        assertThat(escaper.escape("\tFish & Chips\n")).isEqualTo("<tab>Fish <and> Chips<newline>");
    
        // Verify that everything else is left unescaped.
        String safeChars = "\0\u0100\uD800\uDC00\uFFFF";
        assertThat(escaper.escape(safeChars)).isEqualTo(safeChars);
    
        // Ensure that Unicode escapers behave correctly wrt badly formed input.
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Feb 18 15:41:04 GMT 2025
    - 5.2K bytes
    - Click Count (0)
  9. android/guava/src/com/google/common/escape/UnicodeEscaper.java

     * 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
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sat Jan 24 04:06:11 GMT 2026
    - 13.2K bytes
    - Click Count (0)
  10. android/guava/src/com/google/common/html/HtmlEscapers.java

       *
       * <p><b>Note:</b> This escaper only performs minimal escaping to make content structurally
       * compatible with HTML. Specifically, it does not perform entity replacement (symbolic or
       * numeric), so it does not replace non-ASCII code points with character references. This escaper
       * escapes only the following five ASCII characters: {@code '"&<>}.
       */
      public static Escaper htmlEscaper() {
        return HTML_ESCAPER;
      }
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sat Dec 21 03:10:51 GMT 2024
    - 3K bytes
    - Click Count (0)
Back to Top