Class: FileColumn::RealUploadedFile

Inherits:
BaseUploadedFile show all
Defined in:
lib/file_column.rb

Overview

:nodoc:

Direct Known Subclasses

PermanentUploadedFile, TempUploadedFile

Instance Attribute Summary

Attributes inherited from BaseUploadedFile

#magick_errors

Instance Method Summary collapse

Methods inherited from BaseUploadedFile

#absolute_dir, #after_destroy, #after_save, #assign, #create_magick_version_if_needed, #has_magick_errors?, #initialize, #just_uploaded?, #on_save, #options, #relative_dir, #temp_path, #transform_with_magick

Constructor Details

This class inherits a constructor from FileColumn::BaseUploadedFile

Instance Method Details

#absolute_path(subdir = nil) ⇒ Object



172
173
174
175
176
177
178
# File 'lib/file_column.rb', line 172

def absolute_path(subdir=nil)
  if subdir
    File.join(@dir, subdir, @filename)
  else
    File.join(@dir, @filename)
  end
end

#relative_path(subdir = nil) ⇒ Object



180
181
182
183
184
185
186
# File 'lib/file_column.rb', line 180

def relative_path(subdir=nil)
  if subdir
    File.join(relative_path_prefix, subdir, @filename)
  else
    File.join(relative_path_prefix, @filename)
  end
end