Class: Anthropic::Models::Beta::BetaManagedAgentsDeltaContent

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/anthropic/models/beta/beta_managed_agents_delta_content.rb,
sig/anthropic/models/beta/beta_managed_agents_delta_content.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 ⇒ BetaManagedAgentsDeltaContent

Returns a new instance of BetaManagedAgentsDeltaContent.

Parameters:

  • content: (Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock)
  • index: (Integer)
  • type: (:content_delta)


22
23
24
25
26
# File 'sig/anthropic/models/beta/beta_managed_agents_delta_content.rbs', line 22

def initialize: (
  content: Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock,
  ?index: Integer,
  ?type: :content_delta
) -> void

Instance Attribute Details

#content ⇒ Anthropic::Models::Beta::Sessions::BetaManagedAgentsTextBlock

A partial element of the content array at index, typed like the element itself — the same shape the buffered agent.message carries in content.

Parameters:

  • value (Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock)

Returns:



12
# File 'lib/anthropic/models/beta/beta_managed_agents_delta_content.rb', line 12

required :content, -> { Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock }

#index ⇒ Integer?

Which entry in the previewed event's content array this fragment lands in. Insert content as that entry when the index is new; append to the existing entry otherwise.

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


25
# File 'lib/anthropic/models/beta/beta_managed_agents_delta_content.rb', line 25

optional :index, Integer

#type ⇒ Symbol, :content_delta

Parameters:

  • value (:content_delta)

Returns:

  • (Symbol, :content_delta)


17
# File 'lib/anthropic/models/beta/beta_managed_agents_delta_content.rb', line 17

required :type, const: :content_delta

Instance Method Details

#to_hash ⇒ { content: Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock, type: :content_delta, index: Integer }

Returns:

  • ({ content: Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock, type: :content_delta, index: Integer })


28
29
30
31
32
# File 'sig/anthropic/models/beta/beta_managed_agents_delta_content.rbs', line 28

def to_hash: -> {
  content: Anthropic::Beta::Sessions::BetaManagedAgentsTextBlock,
  type: :content_delta,
  index: Integer
}