Class: AssetFingerprinter::PathRewriter
- Inherits:
-
Object
- Object
- AssetFingerprinter::PathRewriter
- Defined in:
- lib/asset_fingerprinter/path_rewriter.rb
Defined Under Namespace
Modules: Format
Instance Attribute Summary collapse
-
#fingerprinter ⇒ Object
Returns the value of attribute fingerprinter.
-
#pattern ⇒ Object
Returns the value of attribute pattern.
Instance Method Summary collapse
- #call(path) ⇒ Object
-
#initialize {|_self| ... } ⇒ PathRewriter
constructor
A new instance of PathRewriter.
Constructor Details
#initialize {|_self| ... } ⇒ PathRewriter
Returns a new instance of PathRewriter.
10 11 12 |
# File 'lib/asset_fingerprinter/path_rewriter.rb', line 10 def initialize yield self if block_given? end |
Instance Attribute Details
#fingerprinter ⇒ Object
Returns the value of attribute fingerprinter.
8 9 10 |
# File 'lib/asset_fingerprinter/path_rewriter.rb', line 8 def fingerprinter @fingerprinter end |
#pattern ⇒ Object
Returns the value of attribute pattern.
8 9 10 |
# File 'lib/asset_fingerprinter/path_rewriter.rb', line 8 def pattern @pattern end |
Instance Method Details
#call(path) ⇒ Object
14 15 16 |
# File 'lib/asset_fingerprinter/path_rewriter.rb', line 14 def call(path) pattern.call(path, fingerprinter.call(path)) end |