Class: Clickwrap::Integrity::Chain::Break

Inherits:
Data
  • Object
show all
Defined in:
lib/clickwrap/integrity/chain.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#chain_scopeObject (readonly)

Returns the value of attribute chain_scope

Returns:

  • (Object)

    the current value of chain_scope



45
46
47
# File 'lib/clickwrap/integrity/chain.rb', line 45

def chain_scope
  @chain_scope
end

#chain_sequenceObject (readonly)

Returns the value of attribute chain_sequence

Returns:

  • (Object)

    the current value of chain_sequence



45
46
47
# File 'lib/clickwrap/integrity/chain.rb', line 45

def chain_sequence
  @chain_sequence
end

#detailObject (readonly)

Returns the value of attribute detail

Returns:

  • (Object)

    the current value of detail



45
46
47
# File 'lib/clickwrap/integrity/chain.rb', line 45

def detail
  @detail
end

#event_idObject (readonly)

Returns the value of attribute event_id

Returns:

  • (Object)

    the current value of event_id



45
46
47
# File 'lib/clickwrap/integrity/chain.rb', line 45

def event_id
  @event_id
end

#reasonObject (readonly)

Returns the value of attribute reason

Returns:

  • (Object)

    the current value of reason



45
46
47
# File 'lib/clickwrap/integrity/chain.rb', line 45

def reason
  @reason
end

Instance Method Details

#to_hObject



46
47
48
49
50
51
52
53
54
# File 'lib/clickwrap/integrity/chain.rb', line 46

def to_h
  {
    "chain_scope" => chain_scope,
    "chain_sequence" => chain_sequence,
    "event_id" => event_id,
    "reason" => reason.to_s,
    "detail" => detail
  }.compact
end

#to_sObject



56
# File 'lib/clickwrap/integrity/chain.rb', line 56

def to_s = "#{chain_scope}##{chain_sequence} #{event_id}: #{detail}"