Class: Hanami::Assets::Bundler::Asset Private
- Inherits:
-
Object
- Object
- Hanami::Assets::Bundler::Asset
- Defined in:
- lib/hanami/assets/bundler/asset.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Constant Summary collapse
- WILDCARD_EXT =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
'.*'.freeze
Instance Attribute Summary collapse
- #configuration ⇒ Object readonly private
- #path ⇒ Object readonly private
Instance Method Summary collapse
- #base64_digest(algorithm) ⇒ Object private
- #expanded_fingerprinted_target ⇒ Object private
- #expanded_path ⇒ Object private
- #fingerprinted_target ⇒ Object private
-
#initialize(path, configuration) ⇒ Asset
constructor
private
Return a new instance.
Constructor Details
#initialize(path, configuration) ⇒ Asset
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Return a new instance
29 30 31 32 |
# File 'lib/hanami/assets/bundler/asset.rb', line 29 def initialize(path, configuration) @path = path @configuration = configuration end |
Instance Attribute Details
#configuration ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/hanami/assets/bundler/asset.rb', line 19 def configuration @configuration end |
#path ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
15 16 17 |
# File 'lib/hanami/assets/bundler/asset.rb', line 15 def path @path end |
Instance Method Details
#base64_digest(algorithm) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
54 55 56 |
# File 'lib/hanami/assets/bundler/asset.rb', line 54 def base64_digest(algorithm) raw_digest(algorithm).base64digest end |
#expanded_fingerprinted_target ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
48 49 50 |
# File 'lib/hanami/assets/bundler/asset.rb', line 48 def ::File.(fingerprinted_target) end |
#expanded_path ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
36 37 38 |
# File 'lib/hanami/assets/bundler/asset.rb', line 36 def ::File.(@path) end |
#fingerprinted_target ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
42 43 44 |
# File 'lib/hanami/assets/bundler/asset.rb', line 42 def fingerprinted_target ::File.join(directory, "#{filename}-#{fingerprint}#{extension}") end |