Bundle.ApplyTransforms Method
Apply the set of IBundleTransform objects to the bundle content.
Namespace: System.Web.Optimization
Assembly: System.Web.Optimization (in System.Web.Optimization.dll)
Syntax
'Declaration
Public Overridable Function ApplyTransforms ( _
context As BundleContext, _
bundleContent As String, _
bundleFiles As IEnumerable(Of VirtualFile) _
) As BundleResponse
'Usage
Dim instance As Bundle
Dim context As BundleContext
Dim bundleContent As String
Dim bundleFiles As IEnumerable(Of VirtualFile)
Dim returnValue As BundleResponse
returnValue = instance.ApplyTransforms(context, _
bundleContent, bundleFiles)
public virtual BundleResponse ApplyTransforms(
BundleContext context,
string bundleContent,
IEnumerable<VirtualFile> bundleFiles
)
public:
virtual BundleResponse^ ApplyTransforms(
BundleContext^ context,
String^ bundleContent,
IEnumerable<VirtualFile^>^ bundleFiles
)
abstract ApplyTransforms :
context:BundleContext *
bundleContent:string *
bundleFiles:IEnumerable<VirtualFile> -> BundleResponse
override ApplyTransforms :
context:BundleContext *
bundleContent:string *
bundleFiles:IEnumerable<VirtualFile> -> BundleResponse
public function ApplyTransforms(
context : BundleContext,
bundleContent : String,
bundleFiles : IEnumerable<VirtualFile>
) : BundleResponse
Parameters
- context
Type: System.Web.Optimization.BundleContext
The BundleContext object that contains state for both the framework configuration and the HTTP request.
- bundleContent
Type: System.String
The compiled content of all files in the bundle.
- bundleFiles
Type: System.Collections.Generic.IEnumerable<VirtualFile>
The list of all file paths in the bundle.
Return Value
Type: System.Web.Optimization.BundleResponse
A BundleResponse object containing the processed bundle contents.
Remarks
ApplyTransforms iterates through each IBundleTransform object that was configured with the bundle when it was created and calls the transform's Process(BundleContext, BundleResponse) method.