Class: SwitchFile::FileType
- Inherits:
-
Valuable
- Object
- Valuable
- SwitchFile::FileType
- Defined in:
- lib/switch_file/file_type.rb
Overview
A type of file within the project
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.all ⇒ Object
8 9 10 |
# File 'lib/switch_file/file_type.rb', line 8 def self.all @all ||= SwitchFile.file_type_attributes.map{|attributes| FileType.new(attributes) } end |
.all=(file_types) ⇒ Object
12 13 14 |
# File 'lib/switch_file/file_type.rb', line 12 def self.all=(file_types) @all = file_types end |
Instance Method Details
#generate_open_command(source_path) ⇒ Object
16 17 18 |
# File 'lib/switch_file/file_type.rb', line 16 def generate_open_command(source_path) open_command.call(source_path.class_name) end |