Linux heracles.o2switch.net 4.18.0-553.62.1.lve.el8.x86_64 #1 SMP Mon Jul 21 17:50:35 UTC 2025 x86_64
/
opt
/
alt
/
ruby27
/
share
/
ri
/
system
/
Bundler
/
Thor
/
Base
/
ClassMethods
/
//opt/alt/ruby27/share/ri/system/Bundler/Thor/Base/ClassMethods/argument-i.ri
U:RDoc::AnyMethod[iI" argument:ETI"/Bundler::Thor::Base::ClassMethods#argument;TF:privateo:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"GAdds an argument to the class and creates an attr_accessor for it.;To:RDoc::Markup::BlankLine o; ; [I"LArguments are different from options in several aspects. The first one ;TI"Kis how they are parsed from the command line, arguments are retrieved ;TI"from position:;T@o:RDoc::Markup::Verbatim; [I"thor command NAME ;T:@format0o; ; [I"Instead of:;T@o;; [I"thor command --name=NAME ;T; 0o; ; [I"RBesides, arguments are used inside your code as an accessor (self.argument), ;TI"9while options are all kept in a hash (self.options).;T@o; ; [ I"IFinally, arguments cannot have type :default or :boolean but can be ;TI"Moptional (supplying :optional => :true or :required => false), although ;TI"Oyou cannot have a required argument after a non-required argument. If you ;TI" try it, an error is raised.;T@S:RDoc::Markup::Heading: leveli : textI"Parameters;To:RDoc::Markup::List: @type: NOTE:@items[o:RDoc::Markup::ListItem:@label[I"name<Symbol>;T; [o; ; [I"The name of the argument.;To;;[I"options<Hash>;T; [o; ; [I"Described below.;T@S;;i ;I"Options;To; ; [I"/:desc - Description for the argument. ;TI"5:required - If the argument is required or not. ;TI"5:optional - If the argument is optional or not. ;TI"T:type - The type of the argument, can be :string, :hash, :array, :numeric. ;TI"a:default - Default value for this argument. It cannot be required and have default values. ;TI"/:banner - String to show on usage notes.;T@S;;i ;I"Errors;To;;;;[o;;[I"ArgumentError;T; [o; ; [I"GRaised if you supply a required argument after a non required one.;T: @fileI"-lib/bundler/vendor/thor/lib/thor/base.rb;T:0@omit_headings_from_table_of_contents_below000[ I"(name, options = {});T@NFI"ClassMethods;TcRDoc::NormalModule00