Class: ModerationAPI::Models::ContentSubmitResponse::Insight::LanguageInsight

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/moderation_api/models/content_submit_response.rb,
sig/moderation_api/models/content_submit_response.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



427
# File 'sig/moderation_api/models/content_submit_response.rbs', line 427

def initialize: (

Instance Attribute Details

#id ⇒ Symbol, :language

Parameters:

  • value (:language)

Returns:

  • (Symbol, :language)


595
# File 'lib/moderation_api/models/content_submit_response.rb', line 595

required :id, const: :language

#probability ⇒ Float

Parameters:

  • value (Float)

Returns:

  • (Float)


600
# File 'lib/moderation_api/models/content_submit_response.rb', line 600

required :probability, Float

#type ⇒ Symbol, :insight

Parameters:

  • value (:insight)

Returns:

  • (Symbol, :insight)


605
# File 'lib/moderation_api/models/content_submit_response.rb', line 605

required :type, const: :insight

#value ⇒ String?

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


610
# File 'lib/moderation_api/models/content_submit_response.rb', line 610

required :value, String, nil?: true

Instance Method Details

#to_hash ⇒ {

Returns:

  • ({)


434
# File 'sig/moderation_api/models/content_submit_response.rbs', line 434

def to_hash: -> {