Class: BitGirder::Core::ListPath

Inherits:
ObjectPath show all
Defined in:
lib/bitgirder/core.rb

Constant Summary

Constants included from BitGirderMethods

BitGirderMethods::PARAM_TYPE_ARG, BitGirderMethods::PARAM_TYPE_ENVVAR, BitGirderMethods::PARAM_TYPE_KEY

Instance Attribute Summary collapse

Attributes inherited from ObjectPath

#parent

Instance Method Summary collapse

Methods inherited from ObjectPath

#descend, #format, get_root, get_root_list, #start_list

Methods included from BitGirderMethods

argv_to_argh, check_fail_prefix, class_name_to_sym, code, compares_to, console, ext_to_class_name, ext_to_sym, has_env, has_key, has_keys, nonnegative, not_nil, positive, raisef, set_from_key, set_var, split_argv, sym_to_cli_switch, sym_to_ext_id, to_bool, unpack_argv_array, unpack_argv_hash, warn

Constructor Details

#initialize(parent, index) ⇒ ListPath

Returns a new instance of ListPath.



1289
1290
1291
1292
1293
# File 'lib/bitgirder/core.rb', line 1289

def initialize( parent, index )
    
    super( parent )
    @index = nonnegative( index, "index" )
end

Instance Attribute Details

#indexObject (readonly)

Returns the value of attribute index.



1287
1288
1289
# File 'lib/bitgirder/core.rb', line 1287

def index
  @index
end

Instance Method Details

#nextObject



1295
1296
1297
# File 'lib/bitgirder/core.rb', line 1295

def next
    ListPath.send( :new, self.parent, @index + 1 )
end