Class: Avm::FileFormats::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/avm/file_formats/base.rb

Direct Known Subclasses

Unknown

Instance Method Summary collapse

Instance Method Details

#apply(_files) ⇒ Enumerable<Avm::FileFormats::FileResult>

Returns:



13
14
15
# File 'lib/avm/file_formats/base.rb', line 13

def apply(_files)
  raise_abstract_method __method__
end

#file_resource_name(path) ⇒ Avm::FileFormats::FileWith

Parameters:

  • path (Pathname)

Returns:

  • (Avm::FileFormats::FileWith)


19
20
21
# File 'lib/avm/file_formats/base.rb', line 19

def file_resource_name(path)
  path.to_pathname.to_path
end

#match?(_file) ⇒ Boolean

Parameters:

  • file (Pathname)

Returns:

  • (Boolean)


29
30
31
# File 'lib/avm/file_formats/base.rb', line 29

def match?(_file)
  raise_abstract_method __method__
end

#nameObject



23
24
25
# File 'lib/avm/file_formats/base.rb', line 23

def name
  self.class.name.demodulize
end