Class: JsonCompleter::ObjectContext

Inherits:
Struct
  • Object
show all
Defined in:
lib/json_completer.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(container:, mode: :key_or_end, current_key: nil) ⇒ ObjectContext

Returns a new instance of ObjectContext.



39
40
41
# File 'lib/json_completer.rb', line 39

def initialize(container:, mode: :key_or_end, current_key: nil)
  super
end

Instance Attribute Details

#container ⇒ Object

Returns the value of attribute container

Returns:

  • (Object) —

    the current value of container



38
39
40
# File 'lib/json_completer.rb', line 38

def container
  @container
end

#current_key ⇒ Object

Returns the value of attribute current_key

Returns:

  • (Object) —

    the current value of current_key



38
39
40
# File 'lib/json_completer.rb', line 38

def current_key
  @current_key
end

#mode ⇒ Object

Returns the value of attribute mode

Returns:

  • (Object) —

    the current value of mode



38
39
40
# File 'lib/json_completer.rb', line 38

def mode
  @mode
end