Class: Jamf::MobileDevicePrestage

Inherits:
OAPISchemas::GetMobileDevicePrestageV2 show all
Includes:
CollectionResource, Prestage
Defined in:
lib/jamf/api/jamf_pro/api_objects/mobile_device_prestage.rb

Overview

A building in the Jamf Pro API

The parent class is the OAPI object representing a single member of the collection, i.e. the ‘GET_OBJECT’ similar to the POST_OBJECT defined in the class below.

Constant Summary collapse

SYNC_PATH =
'syncs'.freeze
SEARCH_RESULT_OBJECT =

The OAPI object class we get back from a ‘list’ query to get the whole collection, or a subset of it. It contains a :results key which is an array of data for objects of the parent class.

Jamf::OAPISchemas::MobileDevicePrestageSearchResultsV2
POST_OBJECT =

The OAPI object class we send with a POST request to make a new member of the collection in Jamf. This is usually the same as the parent class.

Jamf::OAPISchemas::MobileDevicePrestageV2
PUT_OBJECT =

The OAPI object class we send with a PUT request to change an object in Jamf by specifying all its values. Most updates happen this way, and this is usually the same as the parent class

Jamf::OAPISchemas::PutMobileDevicePrestageV2
LIST_PATH =

The path for GETting the list of all objects in the collection, possibly filtered, sorted, and/or paged

REQUIRED for all collection resources

GET_, PUT_, PATCH_, POST_, and DELETE_ paths don’t need to be defined if they are the same as LIST_PATH (followed by an id if needed)

'v2/mobile-device-prestages'.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#cnxJamf::Connection (readonly) Originally defined in module JPAPIResource

#delete_pathString (readonly) Originally defined in module CollectionResource

#get_pathString (readonly) Originally defined in module JPAPIResource

#post_pathString (readonly) Originally defined in module CollectionResource

#update_pathString (readonly) Originally defined in module JPAPIResource

Instance Method Details

#assign(*sns_to_assign) ⇒ Object Also known as: add Originally defined in module Prestage

Assign

#assigned?(sn) ⇒ Boolean Also known as: include? Originally defined in module Prestage

Is this SN assigned to this prestage?

This method uses the instance’s scope object, from a different API path than the class-level .assigned? method.

#assigned_sns(refresh: false) ⇒ Array<String> Originally defined in module Prestage

#deleteObject Originally defined in module CollectionResource

#exist?Boolean Originally defined in module CollectionResource

#initialize(**data) ⇒ Object Originally defined in module CollectionResource

Constructor

#pretty_print_instance_variablesArray Originally defined in module JPAPIResource

Remove large cached items from the instance_variables used to create pretty-print (pp) output.

#saveObject Originally defined in module Prestage

#scope(refresh: false) ⇒ PrestageScope Originally defined in module Prestage

The scope data for this prestage

TODO: retain this caching?

#scope_pathObject Originally defined in module Prestage

The scope endpoint for this instance

#to_sString Originally defined in module CollectionResource

A meaningful string representation of this object

#unassign(*sns_to_unassign) ⇒ Object Also known as: remove Originally defined in module Prestage