Class: Attachment (<Toplevel Module>)

Overview
Module Structure
Class Hierarchy
Class Methods
Attachment.find_by_token / 1
Attachment.attach_files / 2
Attachment.latest_attach / 2
Attachment.prune / 1
Attachment.disk_filename / 1
Instance Methods
Attachment#container_with_blank_type_check
Attachment#copy / 1
Attachment#validate_max_file_size
Attachment#file= / 1
Attachment#file
Attachment#filename= / 1
Attachment#files_to_final_location
Attachment#delete_from_disk
Attachment#diskfile
Attachment#increment_download
Attachment#project
Attachment#visible? / 1
Attachment#deletable? / 1
Attachment#image?
Attachment#is_text?
Attachment#is_diff?
Attachment#readable?
Attachment#token
Attachment#delete_from_disk!
Attachment#sanitize_filename / 1
is a submodule of
module: <Toplevel Module>   
inherits from
  Base ( ActiveRecord )
has properties
method: container_with_blank_type_check   
method: copy / 1   
method: validate_max_file_size   
method: file= / 1   
method: file   
method: filename= / 1   
method: files_to_final_location   
method: delete_from_disk   
method: diskfile   
method: increment_download   
method: project   
method: visible? / 1   
method: deletable? / 1   
method: image?   
method: is_text?   
method: is_diff?   
method: readable?   
method: token   
class method: find_by_token / 1   
class method: attach_files / 2   
class method: latest_attach / 2   
class method: prune / 1   
method: delete_from_disk!   
method: sanitize_filename / 1   
class method: disk_filename / 1   
is defined at
#20 in app/models/attachment.rb  

Overview

Module Structure

  module: <Toplevel Module>
  module: ActiveRecord
class: Base     
✗ class: Attachment

Class Hierarchy

Object ( Builtin-Module )
Base ( ActiveRecord )
has properties
class method: find_ids / 1   
Attachment
has properties
method: container_with_blank_type_check   
method: copy / 1   
method: validate_max_file_size   
method: file= / 1   
method: file   
method: filename= / 1   
method: files_to_final_location   
method: delete_from_disk   
method: diskfile   
method: increment_download   
method: project   
method: visible? / 1   
method: deletable? / 1   
method: image?   
method: is_text?   
method: is_diff?   
method: readable?   
method: token   
class method: find_by_token / 1   
class method: attach_files / 2   
class method: latest_attach / 2   
class method: prune / 1   
method: delete_from_disk!   
method: sanitize_filename / 1   
class method: disk_filename / 1   

Class Methods

Attachment.find_by_token / 1

#179 in app/models/attachment.rb

find_by_token ( token )

Attachment.attach_files / 2

#194 in app/models/attachment.rb

attach_files ( obj ,
  attachments )

Attachment.latest_attach / 2

#200 in app/models/attachment.rb

latest_attach ( attachments ,
  filename )

Attachment.prune / 1

#206 in app/models/attachment.rb

prune ( age=1.day )

Attachment.disk_filename / 1

#229 in app/models/attachment.rb

disk_filename ( filename )

Instance Methods

Attachment#container_with_blank_type_check

#52 in app/models/attachment.rb

container_with_blank_type_check

Attachment#copy / 1

#62 in app/models/attachment.rb

copy ( attributes=nil )

Attachment#validate_max_file_size

#69 in app/models/attachment.rb

validate_max_file_size

Attachment#file= / 1

#75 in app/models/attachment.rb

file= ( incoming_file )

Attachment#file

#94 in app/models/attachment.rb

file

Attachment#filename= / 1

#98 in app/models/attachment.rb

filename= ( arg )

Attachment#files_to_final_location

#108 in app/models/attachment.rb

files_to_final_location

Attachment#delete_from_disk

#129 in app/models/attachment.rb

delete_from_disk

Attachment#diskfile

#136 in app/models/attachment.rb

diskfile

Attachment#increment_download

#140 in app/models/attachment.rb

increment_download

Attachment#project

#144 in app/models/attachment.rb

project

Attachment#visible? / 1

#148 in app/models/attachment.rb

visible? ( user=User.current )

Attachment#deletable? / 1

#152 in app/models/attachment.rb

deletable? ( user=User.current )

Attachment#image?

#156 in app/models/attachment.rb

image?

Attachment#is_text?

#160 in app/models/attachment.rb

is_text?

Attachment#is_diff?

#164 in app/models/attachment.rb

is_diff?

Attachment#readable?

#169 in app/models/attachment.rb

readable?

Attachment#token

#174 in app/models/attachment.rb

token

Attachment#delete_from_disk!

#214 in app/models/attachment.rb

delete_from_disk!

Attachment#sanitize_filename / 1

#220 in app/models/attachment.rb

sanitize_filename ( value )