Class: PuppetDB::Model::Resource

Inherits:
Base
  • Object
show all
Defined in:
lib/puppetdb/model/resource.rb

Class Method Summary collapse

Methods inherited from Base

client, client=, #initialize, query, request

Constructor Details

This class inherits a constructor from PuppetDB::Model::Base

Class Method Details

.get(**arguments) ⇒ Object

Get object from Puppet DB

Pass a list of key: val arguments as filters for the query.

Examples:

Get exported Resources

PuppetDB::Model::Resource.get(exported: true)

Regexp search in title

PuppetDB::Model::Resource.get(title: '^foo.*bar', regexp: true)

Parameters:

  • regexp (Boolean)

    Set this to true for regular expression matching



15
16
17
# File 'lib/puppetdb/model/resource.rb', line 15

def self.get(**arguments)
  super object: 'resources', **arguments
end