Class: ShipEngine::Domain::Carriers::ListCarriers::Carrier

Inherits:
Object
  • Object
show all
Defined in:
lib/shipengine/domain/carriers/list_carriers.rb

Defined Under Namespace

Classes: Option, Package, Service

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(carrier_id:, carrier_code:, account_number:, requires_funded_amount:, balance:, nickname:, friendly_name:, primary:, has_multi_package_supporting_services:, supports_label_messages:, services:, packages:, options:) ⇒ Carrier

Returns a new instance of Carrier.

Parameters:

  • carrier_id (String)
    • e.g. “se-28529731”

  • carrier_code (String)
    • e.g. “se-28529731”

  • account_number (String)
    • e.g. “account_570827”

  • requires_funded_amount (Boolean)
    • e.g. true

  • balance (Float)
    • e.g. 3799.52

  • nickname (String)
    • e.g. “ShipEngine Account - Stamps.com”

  • friendly_name (String)
    • e.g. “Stamps.com”,

  • primary (Boolean)
    • e.g. true,

  • has_multi_package_supporting_services (Boolean)
    • e.g. true,

  • supports_label_messages (Boolean)
    • e.g. true,

  • services (Array<Carrier::Service>)
  • packages (Array<Carrier::Package>)
  • options (Array<Carrier::Option>)


51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 51

def initialize(carrier_id:, carrier_code:, account_number:, requires_funded_amount:, balance:, nickname:, friendly_name:, primary:, has_multi_package_supporting_services:, supports_label_messages:, services:, packages:, options:) # rubocop:todo Metrics/ParameterLists
  @carrier_id = carrier_id
  @carrier_code = carrier_code
  @account_number = 
  @requires_funded_amount = requires_funded_amount
  @balance = balance
  @nickname = nickname
  @friendly_name = friendly_name
  @primary = primary
  @has_multi_package_supporting_services = has_multi_package_supporting_services
  @supports_label_messages = supports_label_messages
  @services = services
  @packages = packages
  @options = options
end

Instance Attribute Details

#account_numberObject (readonly)

Returns the value of attribute account_number.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def 
  @account_number
end

#balanceObject (readonly)

Returns the value of attribute balance.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def balance
  @balance
end

#carrier_codeObject (readonly)

Returns the value of attribute carrier_code.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def carrier_code
  @carrier_code
end

#carrier_idObject (readonly)

Returns the value of attribute carrier_id.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def carrier_id
  @carrier_id
end

#friendly_nameObject (readonly)

Returns the value of attribute friendly_name.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def friendly_name
  @friendly_name
end

#has_multi_package_supporting_servicesObject (readonly)

Returns the value of attribute has_multi_package_supporting_services.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def has_multi_package_supporting_services
  @has_multi_package_supporting_services
end

#nicknameObject (readonly)

Returns the value of attribute nickname.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def nickname
  @nickname
end

#optionsObject (readonly)

Returns the value of attribute options.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def options
  @options
end

#packagesObject (readonly)

Returns the value of attribute packages.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def packages
  @packages
end

#primaryObject (readonly)

Returns the value of attribute primary.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def primary
  @primary
end

#requires_funded_amountObject (readonly)

Returns the value of attribute requires_funded_amount.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def requires_funded_amount
  @requires_funded_amount
end

#servicesObject (readonly)

Returns the value of attribute services.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def services
  @services
end

#supports_label_messagesObject (readonly)

Returns the value of attribute supports_label_messages.



36
37
38
# File 'lib/shipengine/domain/carriers/list_carriers.rb', line 36

def supports_label_messages
  @supports_label_messages
end