org.apache.tapestry5.internal.services

## Class ContextAssetFactory

- java.lang.Object
- - org.apache.tapestry5.internal.services.AbstractAssetFactory
  - - org.apache.tapestry5.internal.services.ContextAssetFactory

- All Implemented Interfaces:
    AssetFactory

      public class ContextAssetFactory
      extends AbstractAssetFactory

  Implementation of `AssetFactory` for assets that are part of the web application context.
  See Also:
    `ContextResource`

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ContextAssetFactory(ResponseCompressionAnalyzer compressionAnalyzer, ResourceChangeTracker resourceChangeTracker, StreamableResourceSource streamableResourceSource, AssetPathConstructor assetPathConstructor, Context context)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Asset` | `createAsset(Resource resource)` Creates an instance of an asset.

    - ### Methods inherited from class org.apache.tapestry5.internal.services.AbstractAssetFactory

      `createAsset, getRootResource, isCompressable`

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

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

- - ### Constructor Detail

    - #### ContextAssetFactory

          public ContextAssetFactory(ResponseCompressionAnalyzer compressionAnalyzer,
                                     ResourceChangeTracker resourceChangeTracker,
                                     StreamableResourceSource streamableResourceSource,
                                     AssetPathConstructor assetPathConstructor,
                                     Context context)

  - ### Method Detail

    - #### createAsset

          public Asset createAsset(Resource resource)

      Description copied from interface: `AssetFactory`
      Creates an instance of an asset. Starting with 5.1.0.0, it is preferred (but not required) that the factory return an instance of `Asset2`.
      Parameters:
        `resource` - a resource within this factories domain (derived from the root resource)
      Returns:
        an Asset for the resource

${project.version} - Copyright © 2003-2015 The Apache Software Foundation.