Class: Sprout::MXMLCDocument

Inherits:
MXMLCHelper show all
Defined in:
lib/sprout/tasks/mxmlc_document.rb

Overview

The MXMLCDocument helper wraps up the asdoc task using either a Singleton or provided ProjectModel instance.

The simple case that uses a Singleton ProjectModel:

document :asdoc

Using a ProjectModel instance:

project_model :model

document :asdoc => :model

Configuring the proxy ASDocTask

document :asdoc do |t|
  t.link_report = 'LinkReport.rpt'
end

Instance Attribute Summary

Attributes inherited from MXMLCHelper

#model, #use_fcsh

Instance Method Summary collapse

Methods inherited from MXMLCHelper

#input, #output, #prerequisites, #task_name

Constructor Details

#initialize(args, &block) ⇒ MXMLCDocument

Returns a new instance of MXMLCDocument.



22
23
24
25
26
27
28
29
30
31
32
33
# File 'lib/sprout/tasks/mxmlc_document.rb', line 22

def initialize(args, &block)
  super
  
  asdoc task_name do |t|
    configure_mxmlc(t, true)
    t.output = model.doc_dir
    t.doc_classes = input
    t.main_title = model.project_name
    yield t if block_given?
  end
  
end

Instance Method Details

#create_inputObject



35
36
37
# File 'lib/sprout/tasks/mxmlc_document.rb', line 35

def create_input
  return File.basename(super).split('.')[0]
end