ruby-jss 0.7.0 → 0.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGES.md +29 -22
  3. data/README.md +66 -86
  4. data/bin/jamfHelperBackgrounder +148 -0
  5. data/bin/netseg-update +0 -1
  6. data/lib/jss.rb +20 -9
  7. data/lib/jss/api_connection.rb +369 -295
  8. data/lib/jss/api_object.rb +651 -418
  9. data/lib/jss/api_object/account.rb +69 -77
  10. data/lib/jss/api_object/advanced_search.rb +201 -236
  11. data/lib/jss/api_object/advanced_search/advanced_computer_search.rb +42 -42
  12. data/lib/jss/api_object/advanced_search/advanced_mobile_device_search.rb +33 -43
  13. data/lib/jss/api_object/advanced_search/advanced_user_search.rb +33 -43
  14. data/lib/jss/api_object/building.rb +39 -52
  15. data/lib/jss/api_object/categorizable.rb +221 -0
  16. data/lib/jss/api_object/category.rb +81 -89
  17. data/lib/jss/api_object/computer.rb +486 -525
  18. data/lib/jss/api_object/computer_invitation.rb +73 -86
  19. data/lib/jss/api_object/criteriable.rb +6 -7
  20. data/lib/jss/api_object/ebook.rb +21 -0
  21. data/lib/jss/api_object/extendable.rb +6 -8
  22. data/lib/jss/api_object/group.rb +0 -3
  23. data/lib/jss/api_object/locatable.rb +19 -20
  24. data/lib/jss/api_object/mac_application.rb +21 -0
  25. data/lib/jss/api_object/mobile_device.rb +30 -21
  26. data/lib/jss/api_object/mobile_device_application.rb +447 -0
  27. data/lib/jss/api_object/mobile_device_configuration_profile.rb +21 -0
  28. data/lib/jss/api_object/osx_configuration_profile.rb +0 -3
  29. data/lib/jss/api_object/package.rb +21 -34
  30. data/lib/jss/api_object/peripheral.rb +16 -18
  31. data/lib/jss/api_object/policy.rb +5 -83
  32. data/lib/jss/api_object/purchasable.rb +11 -13
  33. data/lib/jss/api_object/scopable.rb +11 -12
  34. data/lib/jss/api_object/script.rb +3 -17
  35. data/lib/jss/api_object/self_servable.rb +419 -205
  36. data/lib/jss/api_object/self_servable/icon.rb +179 -0
  37. data/lib/jss/api_object/updatable.rb +35 -34
  38. data/lib/jss/api_object/uploadable.rb +72 -70
  39. data/lib/jss/api_object/user.rb +6 -7
  40. data/lib/jss/api_object/vppable.rb +117 -0
  41. data/lib/jss/client.rb +264 -225
  42. data/lib/jss/db_connection.rb +7 -5
  43. data/lib/jss/exceptions.rb +50 -42
  44. data/lib/jss/ruby_extensions.rb +8 -7
  45. data/lib/jss/ruby_extensions/object.rb +19 -0
  46. data/lib/jss/utility.rb +82 -40
  47. data/lib/jss/version.rb +1 -1
  48. metadata +37 -68
  49. data/bin/jss-webhook-server +0 -3
  50. data/lib/jss/webhooks.rb +0 -53
  51. data/lib/jss/webhooks/README.md +0 -269
  52. data/lib/jss/webhooks/configuration.rb +0 -213
  53. data/lib/jss/webhooks/data/sample_handlers/RestAPIOperation-executable +0 -91
  54. data/lib/jss/webhooks/data/sample_handlers/RestAPIOperation.rb +0 -45
  55. data/lib/jss/webhooks/data/sample_jsons/ComputerAdded.json +0 -27
  56. data/lib/jss/webhooks/data/sample_jsons/ComputerCheckIn.json +0 -27
  57. data/lib/jss/webhooks/data/sample_jsons/ComputerInventoryCompleted.json +0 -27
  58. data/lib/jss/webhooks/data/sample_jsons/ComputerPolicyFinished.json +0 -27
  59. data/lib/jss/webhooks/data/sample_jsons/ComputerPushCapabilityChanged.json +0 -27
  60. data/lib/jss/webhooks/data/sample_jsons/JSSShutdown.json +0 -14
  61. data/lib/jss/webhooks/data/sample_jsons/JSSStartup.json +0 -14
  62. data/lib/jss/webhooks/data/sample_jsons/MobileDeviceCheckIn.json +0 -26
  63. data/lib/jss/webhooks/data/sample_jsons/MobileDeviceCommandCompleted.json +0 -26
  64. data/lib/jss/webhooks/data/sample_jsons/MobileDeviceEnrolled.json +0 -26
  65. data/lib/jss/webhooks/data/sample_jsons/MobileDevicePushSent.json +0 -26
  66. data/lib/jss/webhooks/data/sample_jsons/MobileDeviceUnEnrolled.json +0 -26
  67. data/lib/jss/webhooks/data/sample_jsons/PatchSoftwareTitleUpdated.json +0 -14
  68. data/lib/jss/webhooks/data/sample_jsons/PushSent.json +0 -11
  69. data/lib/jss/webhooks/data/sample_jsons/RestAPIOperation.json +0 -15
  70. data/lib/jss/webhooks/data/sample_jsons/SCEPChallenge.json +0 -10
  71. data/lib/jss/webhooks/data/sample_jsons/SmartGroupComputerMembershipChange.json +0 -13
  72. data/lib/jss/webhooks/data/sample_jsons/SmartGroupMobileDeviceMembershipChange.json +0 -13
  73. data/lib/jss/webhooks/event.rb +0 -139
  74. data/lib/jss/webhooks/event/computer_added.rb +0 -38
  75. data/lib/jss/webhooks/event/computer_check_in.rb +0 -38
  76. data/lib/jss/webhooks/event/computer_inventory_completed.rb +0 -38
  77. data/lib/jss/webhooks/event/computer_policy_finished.rb +0 -38
  78. data/lib/jss/webhooks/event/computer_push_capability_changed.rb +0 -38
  79. data/lib/jss/webhooks/event/handlers.rb +0 -192
  80. data/lib/jss/webhooks/event/jss_shutdown.rb +0 -38
  81. data/lib/jss/webhooks/event/jss_startup.rb +0 -38
  82. data/lib/jss/webhooks/event/mobile_device_check_in.rb +0 -38
  83. data/lib/jss/webhooks/event/mobile_device_command_completed.rb +0 -38
  84. data/lib/jss/webhooks/event/mobile_device_enrolled.rb +0 -38
  85. data/lib/jss/webhooks/event/mobile_device_push_sent.rb +0 -38
  86. data/lib/jss/webhooks/event/mobile_device_unenrolled.rb +0 -38
  87. data/lib/jss/webhooks/event/patch_software_title_updated.rb +0 -38
  88. data/lib/jss/webhooks/event/push_sent.rb +0 -38
  89. data/lib/jss/webhooks/event/rest_api_operation.rb +0 -38
  90. data/lib/jss/webhooks/event/scep_challenge.rb +0 -38
  91. data/lib/jss/webhooks/event/smart_group_computer_membership_change.rb +0 -38
  92. data/lib/jss/webhooks/event/smart_group_mobile_device_membership_change.rb +0 -38
  93. data/lib/jss/webhooks/event/webhook.rb +0 -40
  94. data/lib/jss/webhooks/event_objects.rb +0 -112
  95. data/lib/jss/webhooks/event_objects/computer.rb +0 -49
  96. data/lib/jss/webhooks/event_objects/jss.rb +0 -36
  97. data/lib/jss/webhooks/event_objects/mobile_device.rb +0 -48
  98. data/lib/jss/webhooks/event_objects/patch_software_title_update.rb +0 -38
  99. data/lib/jss/webhooks/event_objects/push.rb +0 -33
  100. data/lib/jss/webhooks/event_objects/rest_api_operation.rb +0 -37
  101. data/lib/jss/webhooks/event_objects/scep_challenge.rb +0 -32
  102. data/lib/jss/webhooks/event_objects/smart_group.rb +0 -35
  103. data/lib/jss/webhooks/server_app.rb +0 -37
  104. data/lib/jss/webhooks/server_app/routes.rb +0 -27
  105. data/lib/jss/webhooks/server_app/routes/handle_webhook_event.rb +0 -39
  106. data/lib/jss/webhooks/server_app/routes/home.rb +0 -37
  107. data/lib/jss/webhooks/server_app/self_signed_cert.rb +0 -65
  108. data/lib/jss/webhooks/server_app/server.rb +0 -60
  109. data/lib/jss/webhooks/version.rb +0 -32
@@ -1,94 +1,94 @@
1
1
  ### Copyright 2017 Pixar
2
2
 
3
- ###
3
+ ###
4
4
  ### Licensed under the Apache License, Version 2.0 (the "Apache License")
5
5
  ### with the following modification; you may not use this file except in
6
6
  ### compliance with the Apache License and the following modification to it:
7
7
  ### Section 6. Trademarks. is deleted and replaced with:
8
- ###
8
+ ###
9
9
  ### 6. Trademarks. This License does not grant permission to use the trade
10
10
  ### names, trademarks, service marks, or product names of the Licensor
11
11
  ### and its affiliates, except as required to comply with Section 4(c) of
12
12
  ### the License and to reproduce the content of the NOTICE file.
13
- ###
13
+ ###
14
14
  ### You may obtain a copy of the Apache License at
15
- ###
15
+ ###
16
16
  ### http://www.apache.org/licenses/LICENSE-2.0
17
- ###
17
+ ###
18
18
  ### Unless required by applicable law or agreed to in writing, software
19
19
  ### distributed under the Apache License with the above modification is
20
20
  ### distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
21
21
  ### KIND, either express or implied. See the Apache License for the specific
22
22
  ### language governing permissions and limitations under the Apache License.
23
- ###
23
+ ###
24
24
  ###
25
25
 
26
26
  ###
27
27
  module JSS
28
28
 
29
- #####################################
30
- ### Module Variables
31
- #####################################
32
29
 
30
+ # Module Variables
33
31
  #####################################
34
- ### Module Methods
35
- #####################################
36
32
 
33
+
34
+ # Module Methods
37
35
  #####################################
38
- ### Classes
36
+
37
+
38
+ # Classes
39
39
  #####################################
40
40
 
41
- ###
42
- ### An AdvancedComputerSearch in the JSS
43
- ###
44
- ### @see JSS::AdvancedSearch
45
- ###
46
- ### @see JSS::APIObject
47
- ###
41
+
42
+ # An AdvancedComputerSearch in the JSS
43
+ #
44
+ # @see JSS::AdvancedSearch
45
+ #
46
+ # @see JSS::APIObject
47
+ #
48
48
  class AdvancedComputerSearch < JSS::AdvancedSearch
49
49
 
50
- #####################################
51
- ### Mix-Ins
52
- #####################################
53
50
 
51
+ # Mix-Ins
54
52
  #####################################
55
- ### Class Constants
53
+
54
+
55
+ # Class Constants
56
56
  #####################################
57
57
 
58
- ### The base for REST resources of this class
59
- RSRC_BASE = "advancedcomputersearches"
58
+ # The base for REST resources of this class
59
+ RSRC_BASE = 'advancedcomputersearches'.freeze
60
60
 
61
- ### the hash key used for the JSON list output of all objects in the JSS
61
+ # the hash key used for the JSON list output of all objects in the JSS
62
62
  RSRC_LIST_KEY = :advanced_computer_searches
63
63
 
64
- ### The hash key used for the JSON object output.
65
- ### It's also used in various error messages
64
+ # The hash key used for the JSON object output.
65
+ # It's also used in various error messages
66
66
  RSRC_OBJECT_KEY = :advanced_computer_search
67
67
 
68
- ### these keys, as well as :id and :name, are present in valid API JSON data for this class
69
- VALID_DATA_KEYS = [:sql_text, :display_fields, :computers]
68
+ # these keys, as well as :id and :name, are present in valid API JSON data for this class
69
+ VALID_DATA_KEYS = [:sql_text, :display_fields, :computers].freeze
70
70
 
71
- ### what kind of thing is returned by this search?
71
+ # what kind of thing is returned by this search?
72
72
  RESULT_CLASS = JSS::Computer
73
73
 
74
- ### what data fields come back along with the display fields
75
- ### for each computer?
76
- RESULT_ID_FIELDS = [:id, :name, :udid]
74
+ # what data fields come back along with the display fields
75
+ # for each computer?
76
+ RESULT_ID_FIELDS = [:id, :name, :udid].freeze
77
77
 
78
- #####################################
79
- ### Attributes
80
- #####################################
81
78
 
82
- #####################################
83
- ### Constructor
79
+ # Attributes
84
80
  #####################################
85
81
 
86
- #####################################
87
- ### Public Instance Methods
82
+
83
+ # Constructor
88
84
  #####################################
89
85
 
86
+
87
+ # Public Instance Methods
90
88
  #####################################
91
- ### Private Instance Methods
89
+
90
+
91
+ # Private Instance Methods
92
92
  #####################################
93
93
 
94
94
  end # class
@@ -1,95 +1,85 @@
1
1
  ### Copyright 2017 Pixar
2
2
 
3
- ###
3
+ ###
4
4
  ### Licensed under the Apache License, Version 2.0 (the "Apache License")
5
5
  ### with the following modification; you may not use this file except in
6
6
  ### compliance with the Apache License and the following modification to it:
7
7
  ### Section 6. Trademarks. is deleted and replaced with:
8
- ###
8
+ ###
9
9
  ### 6. Trademarks. This License does not grant permission to use the trade
10
10
  ### names, trademarks, service marks, or product names of the Licensor
11
11
  ### and its affiliates, except as required to comply with Section 4(c) of
12
12
  ### the License and to reproduce the content of the NOTICE file.
13
- ###
13
+ ###
14
14
  ### You may obtain a copy of the Apache License at
15
- ###
15
+ ###
16
16
  ### http://www.apache.org/licenses/LICENSE-2.0
17
- ###
17
+ ###
18
18
  ### Unless required by applicable law or agreed to in writing, software
19
19
  ### distributed under the Apache License with the above modification is
20
20
  ### distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
21
21
  ### KIND, either express or implied. See the Apache License for the specific
22
22
  ### language governing permissions and limitations under the Apache License.
23
- ###
23
+ ###
24
24
  ###
25
25
 
26
26
  ###
27
27
  module JSS
28
28
 
29
- #####################################
30
- ### Module Variables
29
+ # Module Variables
31
30
  #####################################
32
31
 
33
- #####################################
34
- ### Module Methods
32
+ # Module Methods
35
33
  #####################################
36
34
 
37
- #####################################
38
- ### Classes
35
+ # Classes
39
36
  #####################################
40
37
 
41
- ###
42
- ### An AdvancedComputerSearch in the JSS
43
- ###
44
- ### @see JSS::AdvancedSearch
45
- ###
46
- ### @see JSS::APIObject
47
- ###
38
+ # An AdvancedComputerSearch in the JSS
39
+ #
40
+ # @see JSS::AdvancedSearch
41
+ #
42
+ # @see JSS::APIObject
43
+ #
48
44
  class AdvancedMobileDeviceSearch < JSS::AdvancedSearch
49
45
 
50
- #####################################
51
- ### Mix-Ins
46
+ # Mix-Ins
52
47
  #####################################
53
48
 
54
- #####################################
55
- ### Class Constants
49
+ # Class Constants
56
50
  #####################################
57
51
 
58
- ### The base for REST resources of this class
59
- RSRC_BASE = "advancedmobiledevicesearches"
52
+ # The base for REST resources of this class
53
+ RSRC_BASE = 'advancedmobiledevicesearches'.freeze
60
54
 
61
- ### the hash key used for the JSON list output of all objects in the JSS
62
- ### NOTE - THIS IS A BUG, it should be advanced_mobile_device_searches
55
+ # the hash key used for the JSON list output of all objects in the JSS
56
+ # NOTE - THIS IS A BUG, it should be advanced_mobile_device_searches
63
57
  RSRC_LIST_KEY = :advanced_computer_searches
64
58
 
65
- ### The hash key used for the JSON object output.
66
- ### It's also used in various error messages
59
+ # The hash key used for the JSON object output.
60
+ # It's also used in various error messages
67
61
  RSRC_OBJECT_KEY = :advanced_mobile_device_search
68
62
 
69
- ### these keys, as well as :id and :name, are present in valid API JSON data for this class
70
- VALID_DATA_KEYS = [:sql_text, :display_fields, :mobile_devices]
63
+ # these keys, as well as :id and :name, are present in valid API JSON data for this class
64
+ VALID_DATA_KEYS = [:sql_text, :display_fields, :mobile_devices].freeze
71
65
 
72
- ### what kind of thing is returned by this search?
66
+ # what kind of thing is returned by this search?
73
67
  RESULT_CLASS = JSS::MobileDevice
74
68
 
75
- ### what data fields come back along with the display fields
76
- ### for each mobiledevices?
77
- RESULT_ID_FIELDS = [:id, :name, :udid]
69
+ # what data fields come back along with the display fields
70
+ # for each mobiledevices?
71
+ RESULT_ID_FIELDS = [:id, :name, :udid].freeze
78
72
 
79
- #####################################
80
- ### Attributes
73
+ # Attributes
81
74
  #####################################
82
75
 
83
- #####################################
84
- ### Constructor
76
+ # Constructor
85
77
  #####################################
86
78
 
87
- #####################################
88
- ### Public Instance Methods
79
+ # Public Instance Methods
89
80
  #####################################
90
81
 
91
- #####################################
92
- ### Private Instance Methods
82
+ # Private Instance Methods
93
83
  #####################################
94
84
 
95
85
  end # class
@@ -1,94 +1,84 @@
1
1
  ### Copyright 2017 Pixar
2
2
 
3
- ###
3
+ ###
4
4
  ### Licensed under the Apache License, Version 2.0 (the "Apache License")
5
5
  ### with the following modification; you may not use this file except in
6
6
  ### compliance with the Apache License and the following modification to it:
7
7
  ### Section 6. Trademarks. is deleted and replaced with:
8
- ###
8
+ ###
9
9
  ### 6. Trademarks. This License does not grant permission to use the trade
10
10
  ### names, trademarks, service marks, or product names of the Licensor
11
11
  ### and its affiliates, except as required to comply with Section 4(c) of
12
12
  ### the License and to reproduce the content of the NOTICE file.
13
- ###
13
+ ###
14
14
  ### You may obtain a copy of the Apache License at
15
- ###
15
+ ###
16
16
  ### http://www.apache.org/licenses/LICENSE-2.0
17
- ###
17
+ ###
18
18
  ### Unless required by applicable law or agreed to in writing, software
19
19
  ### distributed under the Apache License with the above modification is
20
20
  ### distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
21
21
  ### KIND, either express or implied. See the Apache License for the specific
22
22
  ### language governing permissions and limitations under the Apache License.
23
- ###
23
+ ###
24
24
  ###
25
25
 
26
26
  ###
27
27
  module JSS
28
28
 
29
- #####################################
30
- ### Module Variables
29
+ # Module Variables
31
30
  #####################################
32
31
 
33
- #####################################
34
- ### Module Methods
32
+ # Module Methods
35
33
  #####################################
36
34
 
37
- #####################################
38
- ### Classes
35
+ # Classes
39
36
  #####################################
40
37
 
41
- ###
42
- ### An AdvancedUserSearch in the JSS
43
- ###
44
- ### @see JSS::AdvancedSearch
45
- ###
46
- ### @see JSS::APIObject
47
- ###
48
- class AdvancedUserSearch < JSS::AdvancedSearch
38
+ # An AdvancedUserSearch in the JSS
39
+ #
40
+ # @see JSS::AdvancedSearch
41
+ #
42
+ # @see JSS::APIObject
43
+ #
44
+ class AdvancedUserSearch < JSS::AdvancedSearch
49
45
 
50
- #####################################
51
- ### Mix-Ins
46
+ # Mix-Ins
52
47
  #####################################
53
48
 
54
- #####################################
55
- ### Class Constants
49
+ # Class Constants
56
50
  #####################################
57
51
 
58
- ### The base for REST resources of this class
59
- RSRC_BASE = "advancedusersearches"
52
+ # The base for REST resources of this class
53
+ RSRC_BASE = 'advancedusersearches'.freeze
60
54
 
61
- ### the hash key used for the JSON list output of all objects in the JSS
55
+ # the hash key used for the JSON list output of all objects in the JSS
62
56
  RSRC_LIST_KEY = :advanced_user_searches
63
57
 
64
- ### The hash key used for the JSON object output.
65
- ### It's also used in various error messages
58
+ # The hash key used for the JSON object output.
59
+ # It's also used in various error messages
66
60
  RSRC_OBJECT_KEY = :advanced_user_search
67
61
 
68
- ### these keys, as well as :id and :name, are present in valid API JSON data for this class
69
- VALID_DATA_KEYS = [:criteria, :display_fields, :users]
62
+ # these keys, as well as :id and :name, are present in valid API JSON data for this class
63
+ VALID_DATA_KEYS = [:criteria, :display_fields, :users].freeze
70
64
 
71
- ### what kind of thing is returned by this search?
65
+ # what kind of thing is returned by this search?
72
66
  RESULT_CLASS = JSS::User
73
67
 
74
- ### what data fields come back along with the display fields
75
- ### for each user?
76
- RESULT_ID_FIELDS = [:id, :name]
68
+ # what data fields come back along with the display fields
69
+ # for each user?
70
+ RESULT_ID_FIELDS = [:id, :name].freeze
77
71
 
78
- #####################################
79
- ### Attributes
72
+ # Attributes
80
73
  #####################################
81
74
 
82
- #####################################
83
- ### Constructor
75
+ # Constructor
84
76
  #####################################
85
77
 
86
- #####################################
87
- ### Public Instance Methods
78
+ # Public Instance Methods
88
79
  #####################################
89
80
 
90
- #####################################
91
- ### Private Instance Methods
81
+ # Private Instance Methods
92
82
  #####################################
93
83
 
94
84
  end # class
@@ -1,93 +1,80 @@
1
1
  ### Copyright 2017 Pixar
2
2
 
3
- ###
3
+ ###
4
4
  ### Licensed under the Apache License, Version 2.0 (the "Apache License")
5
5
  ### with the following modification; you may not use this file except in
6
6
  ### compliance with the Apache License and the following modification to it:
7
7
  ### Section 6. Trademarks. is deleted and replaced with:
8
- ###
8
+ ###
9
9
  ### 6. Trademarks. This License does not grant permission to use the trade
10
10
  ### names, trademarks, service marks, or product names of the Licensor
11
11
  ### and its affiliates, except as required to comply with Section 4(c) of
12
12
  ### the License and to reproduce the content of the NOTICE file.
13
- ###
13
+ ###
14
14
  ### You may obtain a copy of the Apache License at
15
- ###
15
+ ###
16
16
  ### http://www.apache.org/licenses/LICENSE-2.0
17
- ###
17
+ ###
18
18
  ### Unless required by applicable law or agreed to in writing, software
19
19
  ### distributed under the Apache License with the above modification is
20
20
  ### distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
21
21
  ### KIND, either express or implied. See the Apache License for the specific
22
22
  ### language governing permissions and limitations under the Apache License.
23
- ###
23
+ ###
24
24
  ###
25
25
 
26
26
  ###
27
27
  module JSS
28
-
29
- #####################################
30
- ### Module Variables
31
- #####################################
32
28
 
33
- #####################################
34
- ### Module Methods
29
+ # Module Variables
35
30
  #####################################
36
31
 
37
-
32
+ # Module Methods
38
33
  #####################################
39
- ### Classes
34
+
35
+ # Classes
40
36
  #####################################
41
37
 
42
- ###
43
- ### A Building in the JSS.
44
- ### These are simple, in that they only have an ID and a name.
45
- ###
46
- ### @see JSS::APIObject
47
- ###
38
+ # A Building in the JSS.
39
+ # These are simple, in that they only have an ID and a name.
40
+ #
41
+ # @see JSS::APIObject
42
+ #
48
43
  class Building < JSS::APIObject
49
-
50
- #####################################
51
- ### Mix-Ins
44
+
45
+ # Mix-Ins
52
46
  #####################################
53
47
  include JSS::Creatable
54
48
  include JSS::Updatable
55
-
56
- #####################################
57
- ### Class Methods
58
- #####################################
59
-
49
+
50
+ # Class Methods
60
51
  #####################################
61
- ### Class Constants
52
+
53
+ # Class Constants
62
54
  #####################################
63
-
64
- ### The base for REST resources of this class
65
- RSRC_BASE = "buildings"
66
-
67
- ### the hash key used for the JSON list output of all objects in the JSS
55
+
56
+ # The base for REST resources of this class
57
+ RSRC_BASE = 'buildings'.freeze
58
+
59
+ # the hash key used for the JSON list output of all objects in the JSS
68
60
  RSRC_LIST_KEY = :buildings
69
-
70
- ### The hash key used for the JSON object output.
71
- ### It's also used in various error messages
61
+
62
+ # The hash key used for the JSON object output.
63
+ # It's also used in various error messages
72
64
  RSRC_OBJECT_KEY = :building
73
-
74
- ### these keys, as well as :id and :name, are present in valid API JSON data for this class
75
- VALID_DATA_KEYS = []
76
-
77
- #####################################
78
- ### Attributes
79
- #####################################
80
-
81
- #####################################
82
- ### Constructor
65
+
66
+ # these keys, as well as :id and :name, are present in valid API JSON data for this class
67
+ VALID_DATA_KEYS = [].freeze
68
+
69
+ # Attributes
83
70
  #####################################
84
-
85
71
 
72
+ # Constructor
86
73
  #####################################
87
- ### Public Instance Methods
74
+
75
+ # Public Instance Methods
88
76
  #####################################
89
-
90
-
77
+
91
78
  end # class building
92
-
79
+
93
80
  end # module