Class: ServiceNow::Client::CMDB
- Inherits:
-
Api
- Object
- Api
- ServiceNow::Client::CMDB
show all
- Defined in:
- lib/servicenow/client/cmdb.rb
Instance Attribute Summary
Attributes inherited from Api
#connection
Instance Method Summary
collapse
Methods inherited from Api
#delete, #get_many, #get_one, #patch, #post, #put
Constructor Details
#initialize(connection, instance_class) ⇒ CMDB
Returns a new instance of CMDB.
3
4
5
6
|
# File 'lib/servicenow/client/cmdb.rb', line 3
def initialize(connection, instance_class)
super(connection)
@instance_class = instance_class
end
|
Instance Method Details
#all(params = {}) ⇒ Object
8
9
10
|
# File 'lib/servicenow/client/cmdb.rb', line 8
def all(params = {})
get_many "cmdb/instance/#{@instance_class}", params
end
|
#create(params = {}) ⇒ Object
16
17
18
|
# File 'lib/servicenow/client/cmdb.rb', line 16
def create(params = {})
post "cmdb/instance/#{@instance_class}", params
end
|
#find(id) ⇒ Object
12
13
14
|
# File 'lib/servicenow/client/cmdb.rb', line 12
def find(id)
get_one "cmdb/instance/#{@instance_class}/#{id}"
end
|