diff options
author | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2005-10-26 02:44:44 +0000 |
---|---|---|
committer | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2005-10-26 02:44:44 +0000 |
commit | 0d3db7984fd40769cbb29cde76e081cb06204710 (patch) | |
tree | 1d7ae9d3c24ab2e5a5e66e1415a4e6377d835150 /lib/puppet/log.rb | |
parent | a8645a4330b91932c5658eeffa01b446e2ee657a (diff) | |
download | puppet-0d3db7984fd40769cbb29cde76e081cb06204710.tar.gz puppet-0d3db7984fd40769cbb29cde76e081cb06204710.tar.xz puppet-0d3db7984fd40769cbb29cde76e081cb06204710.zip |
adding tags and path accessors
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@730 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'lib/puppet/log.rb')
-rw-r--r-- | lib/puppet/log.rb | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/puppet/log.rb b/lib/puppet/log.rb index 76eb3280b..36759e2b4 100644 --- a/lib/puppet/log.rb +++ b/lib/puppet/log.rb @@ -168,7 +168,7 @@ module Puppet end end - attr_accessor :level, :message, :source, :time + attr_accessor :level, :message, :source, :time, :tags, :path def initialize(args) unless args.include?(:level) && args.include?(:message) && @@ -193,8 +193,15 @@ module Puppet raise Puppet::DevError, "Invalid message level #{level}" end + if args.include?(:tags) + @tags = args[:tags] + end + + if args.include?(:path) + @path = args[:path] + end + Log.newmessage(self) - @@messages.push(self) end def to_s |