Class: GetStream::Generated::Models::HarmConfig
- Inherits:
-
BaseModel
- Object
- BaseModel
- GetStream::Generated::Models::HarmConfig
show all
- Defined in:
- lib/getstream_ruby/generated/models/harm_config.rb
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from BaseModel
#==, #inspect, omit_empty_fields, #to_h, #to_json
Constructor Details
#initialize(attributes = {}) ⇒ HarmConfig
Initialize with attributes
29
30
31
32
33
34
35
36
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 29
def initialize(attributes = {})
super(attributes)
@cooldown_period = attributes[:cooldown_period] || attributes['cooldown_period'] || nil
@severity = attributes[:severity] || attributes['severity'] || nil
@threshold = attributes[:threshold] || attributes['threshold'] || nil
@action_sequences = attributes[:action_sequences] || attributes['action_sequences'] || nil
@harm_types = attributes[:harm_types] || attributes['harm_types'] || nil
end
|
Instance Attribute Details
23
24
25
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 23
def action_sequences
@action_sequences
end
|
#cooldown_period ⇒ Integer
14
15
16
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 14
def cooldown_period
@cooldown_period
end
|
#harm_types ⇒ Array<String>
26
27
28
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 26
def harm_types
@harm_types
end
|
#severity ⇒ Integer
17
18
19
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 17
def severity
@severity
end
|
#threshold ⇒ Integer
20
21
22
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 20
def threshold
@threshold
end
|
Class Method Details
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization
39
40
41
42
43
44
45
46
47
|
# File 'lib/getstream_ruby/generated/models/harm_config.rb', line 39
def self.json_field_mappings
{
cooldown_period: 'cooldown_period',
severity: 'severity',
threshold: 'threshold',
action_sequences: 'action_sequences',
harm_types: 'harm_types'
}
end
|