Class: GetStream::Generated::Models::MarkTypeConfig

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/getstream_ruby/generated/models/mark_type_config.rb

Overview

One mark type's policy.

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 = {}) ⇒ MarkTypeConfig

Initialize with attributes



20
21
22
23
24
# File 'lib/getstream_ruby/generated/models/mark_type_config.rb', line 20

def initialize(attributes = {})
  super(attributes)
  @max_members = attributes.fetch(:max_members) { attributes.fetch('max_members', nil) }
  @requires = attributes.fetch(:requires) { attributes.fetch('requires', nil) }
end

Instance Attribute Details

#max_members ⇒ Integer

Returns Channel size above which the type is off, 1 to 100. Defaults to 100.

Returns:

  • (Integer) —

    Channel size above which the type is off, 1 to 100. Defaults to 100



14
15
16
# File 'lib/getstream_ruby/generated/models/mark_type_config.rb', line 14

def max_members
  @max_members
end

#requires ⇒ Array<String>

Returns Attachment types that qualify a message for the mark, any one of them; 1 to 10 entries, required for a custom type. For a built-in type the list replaces the default, and leaving it out keeps the default.

Returns:

  • (Array<String>) —

    Attachment types that qualify a message for the mark, any one of them; 1 to 10 entries, required for a custom type. For a built-in type the list replaces the default, and leaving it out keeps the default



17
18
19
# File 'lib/getstream_ruby/generated/models/mark_type_config.rb', line 17

def requires
  @requires
end

Class Method Details

.json_field_mappings ⇒ Object

Override field mappings for JSON serialization



27
28
29
30
31
32
# File 'lib/getstream_ruby/generated/models/mark_type_config.rb', line 27

def self.json_field_mappings
  {
    max_members: 'max_members',
    requires: 'requires'
  }
end