Class: ArchUnit::Metrics::FluentApi::CountMetricsBuilder

Inherits:
Object
  • Object
show all
Includes:
MetricReportBuilder
Defined in:
lib/archunit/metrics/fluentapi/count_metrics_builder.rb

Overview

Fluent count-metric names for one immutable metrics scope.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from MetricReportBuilder

#export_as_html

Constructor Details

#initialize(scope) ⇒ CountMetricsBuilder

Returns a new instance of CountMetricsBuilder.

Raises:

  • (ArgumentError)


16
17
18
19
20
21
# File 'lib/archunit/metrics/fluentapi/count_metrics_builder.rb', line 16

def initialize(scope)
  raise ArgumentError, 'scope must be a MetricsBuilder' unless scope.is_a?(MetricsBuilder)

  @scope = scope
  freeze
end

Instance Attribute Details

#scopeObject (readonly)

Returns the value of attribute scope.



14
15
16
# File 'lib/archunit/metrics/fluentapi/count_metrics_builder.rb', line 14

def scope
  @scope
end