Class: PapyTools::CommandeCreateWithHTM

Inherits:
CommandeCreate show all
Defined in:
lib/papy-tools/commande.rb

Instance Method Summary collapse

Methods inherited from CommandeCreate

#filter_erb, #input, #name_output_file, #output, #parametres, #set_invisible

Methods inherited from Commande

instance

Constructor Details

#initializeCommandeCreateWithHTM

Returns a new instance of CommandeCreateWithHTM.



282
283
284
285
# File 'lib/papy-tools/commande.rb', line 282

def initialize()
    super()
    parametres() 
end

Instance Method Details

#runObject



288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
# File 'lib/papy-tools/commande.rb', line 288

def run()

    
    @input_file=ARGV[1]
    if @output
        @output_file=@output
    else
      @output_file=@input_file.split(".").first
    end
    @input_file=File.join("source",@input_file)

    @doc=input(@input_file)
    options={}
    if @liste
        @liste=File.join("source",@liste)
        @doc_liste=input(@liste)
        options[:liste]=@doc_liste
    end
    @tournoi=FabriqueTournoi.instance.construction(@doc,options)
    @presentation=Presentation.new(@tournoi,@invisibles,@filtres)
    filter_erb
    name_output_file
    output
end