Class: Zonesync::Zonefile::Record
- Inherits:
-
Object
- Object
- Zonesync::Zonefile::Record
- Defined in:
- lib/zonesync/zonefile.rb
Instance Attribute Summary collapse
-
#comment ⇒ Object
Returns the value of attribute comment.
- #klass ⇒ Object
-
#ttl ⇒ Object
readonly
Returns the value of attribute ttl.
Class Method Summary collapse
-
.writer_for_ttl(*attribs) ⇒ Object
assign, with handling for global TTL.
Instance Attribute Details
#comment ⇒ Object
Returns the value of attribute comment.
92 93 94 |
# File 'lib/zonesync/zonefile.rb', line 92 def comment @comment end |
#klass ⇒ Object
87 88 89 90 |
# File 'lib/zonesync/zonefile.rb', line 87 def klass @klass = nil if @klass == "" @klass ||= "IN" end |
#ttl ⇒ Object (readonly)
Returns the value of attribute ttl.
83 84 85 |
# File 'lib/zonesync/zonefile.rb', line 83 def ttl @ttl end |
Class Method Details
.writer_for_ttl(*attribs) ⇒ Object
assign, with handling for global TTL
75 76 77 78 79 80 81 |
# File 'lib/zonesync/zonefile.rb', line 75 def self.writer_for_ttl(*attribs) attribs.each do |attrib| define_method "#{attrib}=" do |val| instance_variable_set("@#{attrib}", val || @vars["ttl"]) end end end |