Class: Propshaft::Compiler
- Inherits:
-
Object
- Object
- Propshaft::Compiler
- Defined in:
- lib/propshaft/compiler.rb
Overview
Base compiler from which other compilers can inherit
Direct Known Subclasses
Defined Under Namespace
Classes: CssAssetUrls, JsAssetUrls, SourceMappingUrls
Instance Attribute Summary collapse
-
#assembly ⇒ Object
readonly
Returns the value of attribute assembly.
Instance Method Summary collapse
-
#compile(asset, input) ⇒ Object
Override this in a specific compiler.
-
#initialize(assembly) ⇒ Compiler
constructor
A new instance of Compiler.
- #referenced_by(asset) ⇒ Object
Constructor Details
#initialize(assembly) ⇒ Compiler
Returns a new instance of Compiler.
8 9 10 |
# File 'lib/propshaft/compiler.rb', line 8 def initialize(assembly) @assembly = assembly end |
Instance Attribute Details
#assembly ⇒ Object (readonly)
Returns the value of attribute assembly.
5 6 7 |
# File 'lib/propshaft/compiler.rb', line 5 def assembly @assembly end |
Instance Method Details
#compile(asset, input) ⇒ Object
Override this in a specific compiler
13 14 15 |
# File 'lib/propshaft/compiler.rb', line 13 def compile(asset, input) raise NotImplementedError end |
#referenced_by(asset) ⇒ Object
17 18 19 |
# File 'lib/propshaft/compiler.rb', line 17 def referenced_by(asset) Set.new end |