Class: Icons::Icon::FilePath
- Inherits:
-
Object
- Object
- Icons::Icon::FilePath
- Defined in:
- lib/icons/icon/file_path.rb
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(name:, library:, variant:) ⇒ FilePath
constructor
A new instance of FilePath.
Constructor Details
#initialize(name:, library:, variant:) ⇒ FilePath
Returns a new instance of FilePath.
8 9 10 11 12 |
# File 'lib/icons/icon/file_path.rb', line 8 def initialize(name:, library:, variant:) @name = name @library = library.to_sym @variant = variant&.to_sym end |
Instance Method Details
#call ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/icons/icon/file_path.rb', line 14 def call if animated_library? path = animated_icons_path raise Icons::IconNotFound if path.nil? return path end return custom_library_path if custom_library? app_path end |