org.apache.tapestry5.internal.services

## Class StringInternerImpl

- java.lang.Object
- - org.apache.tapestry5.internal.services.StringInternerImpl

- All Implemented Interfaces:
    StringInterner

      public class StringInternerImpl
      extends Object
      implements StringInterner

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `StringInternerImpl()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `format(String format, Object... arguments)` Formats a string (using `String.format(String, Object[])`) and returns the interned result.
    `String` | `intern(String string)` Interns a string.
    `void` | `setupInvalidation(InvalidationEventHub hub)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### StringInternerImpl

          public StringInternerImpl()

  - ### Method Detail

    - #### setupInvalidation

          @PostInjection
          public void setupInvalidation(@ComponentClasses
                                                       InvalidationEventHub hub)

    - #### intern

          public String intern(String string)

      Description copied from interface: `StringInterner`
      Interns a string.
      Specified by:
        `intern` in interface `StringInterner`
      Parameters:
        `string` - the string to intern
      Returns:
        the input string, or another string instance with the same content

    - #### format

          public String format(String format,
                               Object... arguments)

      Description copied from interface: `StringInterner`
      Formats a string (using `String.format(String, Object[])`) and returns the interned result.
      Specified by:
        `format` in interface `StringInterner`
      Parameters:
        `format` - string format
        `arguments` - used inside the format
      Returns:
        formatted and interned string

5.6.4 - Copyright © 2003-2021 The Apache Software Foundation.