Class: ModernTreasury::Models::Document::File

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/modern_treasury/models/document.rb

Overview

See Also:

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(content_type: nil, filename: nil, size: nil) ⇒ Object

Parameters:

  • content_type (String) (defaults to: nil)

    The MIME content type of the document.

  • filename (String) (defaults to: nil)

    The original filename of the document.

  • size (Integer) (defaults to: nil)

    The size of the document in bytes.



# File 'lib/modern_treasury/models/document.rb', line 211


Instance Attribute Details

#content_typeString?

The MIME content type of the document.

Returns:

  • (String, nil)


197
# File 'lib/modern_treasury/models/document.rb', line 197

optional :content_type, String

#filenameString?

The original filename of the document.

Returns:

  • (String, nil)


203
# File 'lib/modern_treasury/models/document.rb', line 203

optional :filename, String

#sizeInteger?

The size of the document in bytes.

Returns:

  • (Integer, nil)


209
# File 'lib/modern_treasury/models/document.rb', line 209

optional :size, Integer