Class: ModerationAPI::Models::ContentSubmitParams::Policy::IllicitTobacco

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/moderation_api/models/content_submit_params.rb,
sig/moderation_api/models/content_submit_params.rbs

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize ⇒ Object



563
# File 'sig/moderation_api/models/content_submit_params.rbs', line 563

def initialize: (

Instance Attribute Details

#flag ⇒ Boolean

Parameters:

  • value (Boolean)

Returns:

  • (Boolean)


701
# File 'lib/moderation_api/models/content_submit_params.rb', line 701

required :flag, ModerationAPI::Internal::Type::Boolean

#id ⇒ Symbol, :illicit_tobacco

Parameters:

  • value (:illicit_tobacco)

Returns:

  • (Symbol, :illicit_tobacco)


696
# File 'lib/moderation_api/models/content_submit_params.rb', line 696

required :id, const: :illicit_tobacco

#threshold ⇒ Float?

Parameters:

  • (Float)

Returns:

  • (Float, nil)


706
# File 'lib/moderation_api/models/content_submit_params.rb', line 706

optional :threshold, Float

Instance Method Details

#to_hash ⇒ { id: :illicit_tobacco, flag: bool, threshold: Float }

Returns:

  • ({ id: :illicit_tobacco, flag: bool, threshold: Float })


569
# File 'sig/moderation_api/models/content_submit_params.rbs', line 569

def to_hash: -> { id: :illicit_tobacco, flag: bool, threshold: Float }