Class: Log::Facility
- Inherits:
-
Object
- Object
- Log::Facility
- Defined in:
- lib/ec2/amitools/util.rb
Overview
—————————————————————————-#
Constant Summary collapse
- AUTHPRIV =
new "AUTHPRIV"
- CRON =
new "CRON"
- DAEMON =
new "DAEMON"
- FTP =
new "FTP"
- KERN =
new "KERN"
- LOCAL0 =
new "LOCAL0"
- LOCAL1 =
new "LOCAL1"
- LOCAL2 =
new "LOCAL2"
- LOCAL3 =
new "LOCAL3"
- LOCAL4 =
new "LOCAL4"
- LOCAL5 =
new "LOCAL5"
- LOCAL6 =
new "LOCAL6"
- LOCAL7 =
new "LOCAL7"
- LPR =
new "LPR"
- MAIL =
new "MAIL"
- NEWS =
new "NEWS"
- SYSLOG =
new "SYSLOG"
- USER =
new "USER"
- UUCP =
new "UUCP"
- AES =
new "AES"
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(name) ⇒ Facility
constructor
A new instance of Facility.
- #to_s ⇒ Object
Constructor Details
#initialize(name) ⇒ Facility
Returns a new instance of Facility.
171 172 173 174 |
# File 'lib/ec2/amitools/util.rb', line 171 def initialize(name) @name = name @value = (name == "AES")?(12<<3):eval("Syslog::LOG_#{name}") end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
198 199 200 |
# File 'lib/ec2/amitools/util.rb', line 198 def name @name end |
#value ⇒ Object
Returns the value of attribute value.
197 198 199 |
# File 'lib/ec2/amitools/util.rb', line 197 def value @value end |
Instance Method Details
#to_s ⇒ Object
200 201 202 |
# File 'lib/ec2/amitools/util.rb', line 200 def to_s "Facility[LOG_#{@name}]" end |