Class: Google::Apis::GamesV1::RoomAutoMatchingCriteria

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/games_v1/classes.rb,
generated/google/apis/games_v1/representations.rb,
generated/google/apis/games_v1/representations.rb

Overview

This is a JSON template for a room auto-match criteria object.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ RoomAutoMatchingCriteria

Returns a new instance of RoomAutoMatchingCriteria.



2985
2986
2987
# File 'generated/google/apis/games_v1/classes.rb', line 2985

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#exclusive_bitmaskFixnum

A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the result must be zero. Can be used to support exclusive roles within a game. Corresponds to the JSON property exclusiveBitmask

Returns:

  • (Fixnum)


2965
2966
2967
# File 'generated/google/apis/games_v1/classes.rb', line 2965

def exclusive_bitmask
  @exclusive_bitmask
end

#kindString

Uniquely identifies the type of this resource. Value is always the fixed string games#roomAutoMatchingCriteria. Corresponds to the JSON property kind

Returns:

  • (String)


2971
2972
2973
# File 'generated/google/apis/games_v1/classes.rb', line 2971

def kind
  @kind
end

#max_auto_matching_playersFixnum

The maximum number of players that should be added to the room by auto- matching. Corresponds to the JSON property maxAutoMatchingPlayers

Returns:

  • (Fixnum)


2977
2978
2979
# File 'generated/google/apis/games_v1/classes.rb', line 2977

def max_auto_matching_players
  @max_auto_matching_players
end

#min_auto_matching_playersFixnum

The minimum number of players that should be added to the room by auto- matching. Corresponds to the JSON property minAutoMatchingPlayers

Returns:

  • (Fixnum)


2983
2984
2985
# File 'generated/google/apis/games_v1/classes.rb', line 2983

def min_auto_matching_players
  @min_auto_matching_players
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2990
2991
2992
2993
2994
2995
# File 'generated/google/apis/games_v1/classes.rb', line 2990

def update!(**args)
  @exclusive_bitmask = args[:exclusive_bitmask] if args.key?(:exclusive_bitmask)
  @kind = args[:kind] if args.key?(:kind)
  @max_auto_matching_players = args[:max_auto_matching_players] if args.key?(:max_auto_matching_players)
  @min_auto_matching_players = args[:min_auto_matching_players] if args.key?(:min_auto_matching_players)
end