Module: PuppetBind::Provider::NsUpdate

Defined in:
lib/puppet_bind/provider/nsupdate.rb

Instance Method Summary collapse

Instance Method Details

#createObject



16
17
18
19
20
# File 'lib/puppet_bind/provider/nsupdate.rb', line 16

def create
  update do |file|
    accio(file)
  end
end

#destroyObject



22
23
24
25
26
# File 'lib/puppet_bind/provider/nsupdate.rb', line 22

def destroy
  update do |file|
    destructo(file)
  end
end

#exists?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'lib/puppet_bind/provider/nsupdate.rb', line 12

def exists?
  !(query.empty?)
end

#flushObject



28
29
30
31
32
33
34
# File 'lib/puppet_bind/provider/nsupdate.rb', line 28

def flush
  return if @properties.empty?
  update do |file|
    accio(file)
    destructo(file)
  end
end

#ttlObject



36
37
38
# File 'lib/puppet_bind/provider/nsupdate.rb', line 36

def ttl
  query.first[:ttl]
end

#ttl=(ttl) ⇒ Object



40
41
42
# File 'lib/puppet_bind/provider/nsupdate.rb', line 40

def ttl=(ttl)
  @properties[:ttl] = ttl
end