# File lib/puppet/provider/nameservice/directoryservice.rb, line 224
224:     def self.single_report(resource_name, *type_properties)
225:         # JJM 2007-07-24:
226:         #     Given a the name of an object and a list of properties of that
227:         #     object, return all property values in a hash.
228:         #
229:         #     This class method returns nil if the object doesn't exist
230:         #     Otherwise, it returns a hash of the object properties.
231: 
232:         all_present_str_array = list_all_present()
233: 
234:         # NBK: shortcut the process if the resource is missing
235:         return nil unless all_present_str_array.include? resource_name
236: 
237:         dscl_vector = get_exec_preamble("-read", resource_name)
238:         begin
239:             dscl_output = execute(dscl_vector)
240:         rescue Puppet::ExecutionFailure => detail
241:             fail("Could not get report.  command execution failed.")
242:         end
243: 
244:         # Two code paths is ugly, but until we can drop 10.4 support we don't
245:         # have a lot of choice. Ultimately this should all be done using Ruby
246:         # to access the DirectoryService APIs directly, but that's simply not
247:         # feasible for a while yet.
248:         case self.get_macosx_version_major
249:         when "10.4"
250:             dscl_plist = self.parse_dscl_url_data(dscl_output)
251:         when "10.5", "10.6"
252:             dscl_plist = self.parse_dscl_plist_data(dscl_output)
253:         end
254: 
255:         return self.generate_attribute_hash(dscl_plist, *type_properties)
256:     end