class Buildr::JavaNCSS::Config

Attributes

config_directory[W]
enabled[W]
fail_on_error[W]
html_output_file[W]
project[R]
report_dir[W]
style_file[W]
xml_output_file[W]

Public Class Methods

new(project) click to toggle source
# File addon/buildr/javancss.rb, line 107
def initialize(project)
  @project = project
end

Public Instance Methods

config_directory() click to toggle source
# File addon/buildr/javancss.rb, line 67
def config_directory
  @config_directory || project._(:source, :main, :etc, :javancss)
end
enabled?() click to toggle source
# File addon/buildr/javancss.rb, line 55
def enabled?
  !!@enabled
end
fail_on_error?() click to toggle source
# File addon/buildr/javancss.rb, line 79
def fail_on_error?
  @fail_on_error.nil? ? false : @fail_on_error
end
html_enabled?() click to toggle source
# File addon/buildr/javancss.rb, line 61
def html_enabled?
  File.exist?(self.style_file)
end
html_output_file() click to toggle source
# File addon/buildr/javancss.rb, line 91
def html_output_file
  @html_output_file || "#{self.report_dir}/javancss.html"
end
report_dir() click to toggle source
# File addon/buildr/javancss.rb, line 73
def report_dir
  @report_dir || project._(:reports, :javancss)
end
source_paths() click to toggle source
# File addon/buildr/javancss.rb, line 101
def source_paths
  @source_paths ||= [self.project.compile.sources, self.project.test.compile.sources]
end
style_file() click to toggle source
# File addon/buildr/javancss.rb, line 97
def style_file
  @style_file || "#{self.config_directory}/javancss2html.xsl"
end
xml_output_file() click to toggle source
# File addon/buildr/javancss.rb, line 85
def xml_output_file
  @xml_output_file || "#{self.report_dir}/javancss.xml"
end