Class: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::Operation::UpdateFile

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/beta/beta_response_input_item.rb,
sig/openai/models/beta/beta_response_input_item.rbs

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, 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, coerce_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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 ⇒ UpdateFile

Returns a new instance of UpdateFile.

Parameters:

  • diff —

    Unified diff content to apply to the existing file.

  • path —

    Path of the file to update relative to the workspace root.

  • type —

    The operation type. Always update_file.

  • diff: (String)
  • path: (String)
  • type: (:update_file)


2190
2191
2192
2193
2194
# File 'sig/openai/models/beta/beta_response_input_item.rbs', line 2190

def initialize: (
  diff: String,
  path: String,
  ?type: :update_file
) -> void

Instance Attribute Details

#diff ⇒ String

Unified diff content to apply to the existing file.

Returns:

  • (String)


2460
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2460

required :diff, String

#path ⇒ String

Path of the file to update relative to the workspace root.

Returns:

  • (String)


2466
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2466

required :path, String

#type ⇒ :update_file

The operation type. Always update_file.

Returns:

  • (:update_file)


2472
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2472

required :type, const: :update_file

Instance Method Details

#to_hash ⇒ { diff: String, path: String, ?type: :update_file }

Returns:

  • ({ diff: String, path: String, ?type: :update_file })


2196
2197
2198
2199
2200
# File 'sig/openai/models/beta/beta_response_input_item.rbs', line 2196

def to_hash: -> {
  diff: String,
  path: String,
  ?type: :update_file
}