Class: ApplicationInsights::Channel::Contracts::ExceptionDetails

Inherits:
JsonSerializable
  • Object
show all
Defined in:
lib/application_insights/channel/contracts/exception_details.rb

Overview

Data contract class for type ExceptionDetails.

Instance Method Summary collapse

Methods inherited from JsonSerializable

#to_h, #to_json

Constructor Details

#initialize(options = {}) ⇒ ExceptionDetails

Initializes a new instance of the ExceptionDetails class.



9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 9

def initialize(options={})
  defaults = {
    'id' => nil,
    'outerId' => nil,
    'typeName' => nil,
    'message' => nil,
    'hasFullStack' => true,
    'stack' => nil,
    'parsedStack' => []
  }
  values = {
    'typeName' => nil,
    'message' => nil,
    'hasFullStack' => true
  }
  super defaults, values, options
end

Instance Method Details

#has_full_stackObject

Gets the has_full_stack property.



80
81
82
83
84
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 80

def has_full_stack
  @values.fetch('hasFullStack') { 
    @values['hasFullStack'] = true
  }
end

#has_full_stack=(value) ⇒ Object

Sets the has_full_stack property.



87
88
89
90
91
92
93
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 87

def has_full_stack=(value)
  if value == @defaults['hasFullStack']
    @values.delete 'hasFullStack' if @values.key? 'hasFullStack'
  else
    @values['hasFullStack'] = value
  end
end

#idObject

Gets the id property.



28
29
30
31
32
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 28

def id
  @values.fetch('id') { 
    @values['id'] = nil
  }
end

#id=(value) ⇒ Object

Sets the id property.



35
36
37
38
39
40
41
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 35

def id=(value)
  if value == @defaults['id']
    @values.delete 'id' if @values.key? 'id'
  else
    @values['id'] = value
  end
end

#messageObject

Gets the message property.



70
71
72
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 70

def message
  @values['message']
end

#message=(value) ⇒ Object

Sets the message property.



75
76
77
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 75

def message=(value)
  @values['message'] = value
end

#outer_idObject

Gets the outer_id property.



44
45
46
47
48
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 44

def outer_id
  @values.fetch('outerId') { 
    @values['outerId'] = nil
  }
end

#outer_id=(value) ⇒ Object

Sets the outer_id property.



51
52
53
54
55
56
57
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 51

def outer_id=(value)
  if value == @defaults['outerId']
    @values.delete 'outerId' if @values.key? 'outerId'
  else
    @values['outerId'] = value
  end
end

#parsed_stackObject

Gets the parsed_stack property.



112
113
114
115
116
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 112

def parsed_stack
  @values.fetch('parsedStack') { 
    @values['parsedStack'] = []
  }
end

#parsed_stack=(value) ⇒ Object

Sets the parsed_stack property.



119
120
121
122
123
124
125
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 119

def parsed_stack=(value)
  if value == @defaults['parsedStack']
    @values.delete 'parsedStack' if @values.key? 'parsedStack'
  else
    @values['parsedStack'] = value
  end
end

#stackObject

Gets the stack property.



96
97
98
99
100
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 96

def stack
  @values.fetch('stack') { 
    @values['stack'] = nil
  }
end

#stack=(value) ⇒ Object

Sets the stack property.



103
104
105
106
107
108
109
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 103

def stack=(value)
  if value == @defaults['stack']
    @values.delete 'stack' if @values.key? 'stack'
  else
    @values['stack'] = value
  end
end

#type_nameObject

Gets the type_name property.



60
61
62
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 60

def type_name
  @values['typeName']
end

#type_name=(value) ⇒ Object

Sets the type_name property.



65
66
67
# File 'lib/application_insights/channel/contracts/exception_details.rb', line 65

def type_name=(value)
  @values['typeName'] = value
end