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, #store, #temp_path, #transform_with_magick

Constructor Details

This class inherits a constructor from FileColumn::BaseUploadedFile

Instance Method Details

#absolute_path(subdir = nil) ⇒ Object



185
186
187
188
189
190
191
# File 'lib/file_column.rb', line 185

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

#relative_path(subdir = nil) ⇒ Object



193
194
195
196
197
198
199
# File 'lib/file_column.rb', line 193

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