Class: Cadenya::Types::ToolSetAdapter_JustInTime

Inherits:
Object
  • Object
show all
Defined in:
lib/cadenya/types.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(enabled: nil, fail_objective_on_tool_list_error: nil) ⇒ ToolSetAdapter_JustInTime

Returns a new instance of ToolSetAdapter_JustInTime.



6060
6061
6062
6063
# File 'lib/cadenya/types.rb', line 6060

def initialize(enabled: nil, fail_objective_on_tool_list_error: nil)
  @enabled = enabled
  @fail_objective_on_tool_list_error = fail_objective_on_tool_list_error
end

Instance Attribute Details

#enabledObject (readonly)

Returns the value of attribute enabled.



6058
6059
6060
# File 'lib/cadenya/types.rb', line 6058

def enabled
  @enabled
end

#fail_objective_on_tool_list_errorObject (readonly)

Returns the value of attribute fail_objective_on_tool_list_error.



6058
6059
6060
# File 'lib/cadenya/types.rb', line 6058

def fail_objective_on_tool_list_error
  @fail_objective_on_tool_list_error
end

Class Method Details

.from_json(data) ⇒ Object



6065
6066
6067
6068
6069
6070
# File 'lib/cadenya/types.rb', line 6065

def self.from_json(data)
  new(
    enabled: data["enabled"],
    fail_objective_on_tool_list_error: data["failObjectiveOnToolListError"],
  )
end

Instance Method Details

#to_hObject



6072
6073
6074
6075
6076
6077
# File 'lib/cadenya/types.rb', line 6072

def to_h
  {
    enabled: Util.plain(@enabled),
    fail_objective_on_tool_list_error: Util.plain(@fail_objective_on_tool_list_error),
  }.reject { |_k, v| v.nil? }
end