Class: SassProf::ExtProfiler

Inherits:
Profiler show all
Defined in:
lib/sass-prof/ext_profiler.rb

Constant Summary

Constants inherited from Profiler

Profiler::PERFORMABLE_ACTIONS

Instance Method Summary collapse

Methods inherited from Profiler

#start, #stop

Constructor Details

#initialize(subject, action, args = nil, env = nil) ⇒ ExtProfiler

Returns a new instance of ExtProfiler.



4
5
6
# File 'lib/sass-prof/ext_profiler.rb', line 4

def initialize(subject, action, args = nil, env = nil)
  super subject, action, args, env
end

Instance Method Details

#argsObject



12
13
14
# File 'lib/sass-prof/ext_profiler.rb', line 12

def args
  @subject.members.join ", "
end

#nameObject



8
9
10
# File 'lib/sass-prof/ext_profiler.rb', line 8

def name
  @env.members.join(", ").tr "\n", ""
end

#signatureObject



16
17
18
19
# File 'lib/sass-prof/ext_profiler.rb', line 16

def signature
  "#{Formatter.colorize(name, :blue)} < "\
  "#{Formatter.colorize(args, :purple)}"
end