Class: Xberg::AuthConfigHeader

Inherits:
Data
  • Object
show all
Extended by:
T::Sig
Includes:
AuthConfig
Defined in:
lib/xberg/native.rb

Overview

Custom authentication header.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



606
607
608
# File 'lib/xberg/native.rb', line 606

def name
  @name
end

#valueObject (readonly)

Returns the value of attribute value

Returns:

  • (Object)

    the current value of value



606
607
608
# File 'lib/xberg/native.rb', line 606

def value
  @value
end

Class Method Details

.from_hash(hash) ⇒ Object



625
626
627
# File 'lib/xberg/native.rb', line 625

def self.from_hash(hash)
  new(name: hash[:name] || hash["name"], value: hash[:value] || hash["value"])
end

Instance Method Details

#basic?Boolean

Returns:

  • (Boolean)


617
# File 'lib/xberg/native.rb', line 617

def basic? = false

#bearer?Boolean

Returns:

  • (Boolean)


619
# File 'lib/xberg/native.rb', line 619

def bearer? = false

#header?Boolean

Returns:

  • (Boolean)


621
622
623
# File 'lib/xberg/native.rb', line 621

def header? = true
# @param hash [Hash] deserialized from the native extension
# @return [self]