Class: Believe::Models::Biscuit

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/believe/models/biscuit.rb

Overview

Defined Under Namespace

Modules: Type

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(id:, message:, pairs_well_with:, ted_note:, type:, warmth_level:) ⇒ Object

A biscuit from Ted.

Parameters:

  • id (String)

    Biscuit identifier

  • message (String)

    Message that comes with the biscuit

  • pairs_well_with (String)

    What this biscuit pairs well with

  • ted_note (String)

    A handwritten note from Ted

  • type (Symbol, ::Believe::Models::Biscuit::Type)

    Type of biscuit

  • warmth_level (Integer)

    How warm and fresh (1-10)



# File 'lib/believe/models/biscuit.rb', line 43

Instance Attribute Details

#idString

Biscuit identifier

Returns:

  • (String)


11
# File 'lib/believe/models/biscuit.rb', line 11

required :id, String

#messageString

Message that comes with the biscuit

Returns:

  • (String)


17
# File 'lib/believe/models/biscuit.rb', line 17

required :message, String

#pairs_well_withString

What this biscuit pairs well with

Returns:

  • (String)


23
# File 'lib/believe/models/biscuit.rb', line 23

required :pairs_well_with, String

#ted_noteString

A handwritten note from Ted

Returns:

  • (String)


29
# File 'lib/believe/models/biscuit.rb', line 29

required :ted_note, String

#typeSymbol, ::Believe::Models::Biscuit::Type

Type of biscuit



35
# File 'lib/believe/models/biscuit.rb', line 35

required :type, enum: -> { ::Believe::Biscuit::Type }

#warmth_levelInteger

How warm and fresh (1-10)

Returns:

  • (Integer)


41
# File 'lib/believe/models/biscuit.rb', line 41

required :warmth_level, Integer