Package org.apache.tapestry5.internal.util

## Class MessageCatalogResource

- java.lang.Object
- - org.apache.tapestry5.internal.util.VirtualResource
  - - org.apache.tapestry5.internal.util.MessageCatalogResource

- All Implemented Interfaces:
    `Resource`

      public class MessageCatalogResource
      extends VirtualResource

- - ### Field Summary

    - ### Fields inherited from class org.apache.tapestry5.internal.util.VirtualResource

      `UTF8`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `MessageCatalogResource​(java.util.Locale locale, ComponentMessagesSource messagesSource, ResourceChangeTracker changeTracker, boolean compactJSON)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `java.lang.String` | `getFile()` | StreamableResourceSourceImpl needs a file, and a suffix, to determine the content type.
    `java.io.InputStream` | `openStream()` | Opens a stream to the content of the resource, or returns null if the resource does not exist.
    `java.lang.String` | `toString()` |
    `java.net.URL` | `toURL()` | To work as a streamable resource, must return a value (or null) from toURL.

    - ### Methods inherited from class org.apache.tapestry5.internal.util.VirtualResource

      `exists, forFile, forLocale, getFolder, getPath, isVirtual, toInputStream, toInputStream, withExtension`

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

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

- - ### Constructor Detail

    - #### MessageCatalogResource

          public MessageCatalogResource​(java.util.Locale locale,
                                        ComponentMessagesSource messagesSource,
                                        ResourceChangeTracker changeTracker,
                                        boolean compactJSON)

  - ### Method Detail

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

    - #### getFile

          public java.lang.String getFile()

      StreamableResourceSourceImpl needs a file, and a suffix, to determine the content type.
      Specified by:
        `getFile` in interface `Resource`
      Overrides:
        `getFile` in class `VirtualResource`

    - #### toURL

          public java.net.URL toURL()

      To work as a streamable resource, must return a value (or null) from toURL.
      Specified by:
        `toURL` in interface `Resource`
      Overrides:
        `toURL` in class `VirtualResource`

    - #### openStream

          public java.io.InputStream openStream()
                                         throws java.io.IOException

      Description copied from interface: `Resource`
      Opens a stream to the content of the resource, or returns null if the resource does not exist. The native input stream supplied by the resource is wrapped in a `BufferedInputStream`.
      Returns:
        an open, buffered stream to the content, if available
      Throws:
        `java.io.IOException`