Interface JSBundleAsset

All Superinterfaces:
JSBundleObject
All Known Subinterfaces:
JSModule, JSResolvableBundleAsset

public interface JSBundleAsset extends JSBundleObject
Provides contents of a JSBundleObject. These contents can be requested from external apps by using a portal URL or InputStream.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the asset's contents.
    Returns the asset's public URL.

    Methods inherited from interface com.liferay.frontend.js.loader.modules.extender.npm.JSBundleObject

    getId, getName
  • Method Details

    • getInputStream

      InputStream getInputStream() throws IOException
      Returns the asset's contents.
      Returns:
      an InputStream that allows reading the bytes inside the asset
      Throws:
      IOException - if an IO exception occurred
    • getURL

      String getURL()
      Returns the asset's public URL. This URL can be used to retrieve the asset's contents from external apps by making an HTTP request to the portal.
      Returns:
      the asset's public URL