Method: Puppet::Provider::NameService#getinfo
- Defined in:
- lib/puppet/provider/nameservice.rb
#getinfo(refresh) ⇒ Object
Retrieve what we can about our object
223 224 225 226 227 228 229 230 231 232 233 234 235 |
# File 'lib/puppet/provider/nameservice.rb', line 223 def getinfo(refresh) if @objectinfo.nil? or refresh == true @etcmethod ||= ("get" + self.class.section.to_s + "nam").intern begin @objectinfo = Puppet::Etc.send(@etcmethod, @canonical_name) rescue ArgumentError @objectinfo = nil end end # Now convert our Etc struct into a hash. @objectinfo ? info2hash(@objectinfo) : nil end |