class ContentDisposition

Defined in:

content_disposition.cr

Constant Summary

ATTACHMENT = "attachment"
DEFAULT_TO_ASCII = ->(filename : String) do array = [] of Char filename.each_char do |char| array << (char.ascii? ? char : '?') end array.join end
INLINE = "inline"
RFC_5987_ESCAPED_CHAR = /[^A-Za-z0-9!#$&+.^_`|~-]/
TRADITIONAL_ESCAPED_CHAR = /[^ A-Za-z0-9!#$+.^_`|~-]/

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(disposition : String | Symbol, filename : String?, to_ascii : Proc(String, String)? = nil) #

[View source]

Class Method Detail

def self.attachment(filename = nil) #

[View source]
def self.call(**options) #

[View source]
def self.format(**options) #

[View source]
def self.inline(filename = nil) #

[View source]
def self.to_ascii : Proc(String, String)? #

[View source]
def self.to_ascii=(to_ascii : Proc(String, String)?) #

[View source]

Instance Method Detail

def ascii_filename : String? #

[View source]
def disposition : String | Symbol #

[View source]
def filename : String? #

[View source]
def to_ascii : String -> String? #

[View source]
def to_s #
Description copied from class Object

Returns a string representation of this object.

Descendants must usually not override this method. Instead, they must override to_s(io), which must append to the given IO object.


[View source]
def utf8_filename : String? #

[View source]