comet_backup_ruby_sdk 1.12.0 → 1.15.0

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.
@@ -56,6 +56,9 @@ module Comet
56
56
  # @type [String] path_header_image
57
57
  attr_accessor :path_header_image
58
58
 
59
+ # @type [String] path_app_icon_image
60
+ attr_accessor :path_app_icon_image
61
+
59
62
  # @type [String] package_identifier
60
63
  attr_accessor :package_identifier
61
64
 
@@ -109,6 +112,7 @@ module Comet
109
112
  @path_eula_rtf = ''
110
113
  @path_tile_png = ''
111
114
  @path_header_image = ''
115
+ @path_app_icon_image = ''
112
116
  @package_identifier = ''
113
117
  @windows_code_sign_pkcs12file_path = ''
114
118
  @windows_code_sign_pkcs12password_format = 0
@@ -188,6 +192,10 @@ module Comet
188
192
  raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
189
193
 
190
194
  @path_header_image = v
195
+ when 'PathAppIconImage'
196
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
197
+
198
+ @path_app_icon_image = v
191
199
  when 'PackageIdentifier'
192
200
  raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
193
201
 
@@ -254,6 +262,7 @@ module Comet
254
262
  ret['PathEulaRtf'] = @path_eula_rtf
255
263
  ret['PathTilePng'] = @path_tile_png
256
264
  ret['PathHeaderImage'] = @path_header_image
265
+ ret['PathAppIconImage'] = @path_app_icon_image
257
266
  ret['PackageIdentifier'] = @package_identifier
258
267
  ret['WindowsCodeSignPKCS12FilePath'] = @windows_code_sign_pkcs12file_path
259
268
  ret['WindowsCodeSignPKCS12PasswordFormat'] = @windows_code_sign_pkcs12password_format
@@ -0,0 +1,108 @@
1
+ #!/usr/bin/env ruby --enable-frozen-string-literal
2
+ #
3
+ # Copyright (c) 2020-2022 Comet Licensing Ltd.
4
+ # Please see the LICENSE file for usage information.
5
+ #
6
+ # SPDX-License-Identifier: MIT
7
+ #
8
+ # frozen_string_literal: true
9
+
10
+ require 'json'
11
+
12
+ module Comet
13
+
14
+ # DaysOfWeekConfig is a typed class wrapper around the underlying Comet Server API data structure.
15
+ class DaysOfWeekConfig
16
+
17
+ # @type [Boolean] sunday
18
+ attr_accessor :sunday
19
+
20
+ # @type [Boolean] monday
21
+ attr_accessor :monday
22
+
23
+ # @type [Boolean] tuesday
24
+ attr_accessor :tuesday
25
+
26
+ # @type [Boolean] wednesday
27
+ attr_accessor :wednesday
28
+
29
+ # @type [Boolean] thursday
30
+ attr_accessor :thursday
31
+
32
+ # @type [Boolean] friday
33
+ attr_accessor :friday
34
+
35
+ # @type [Boolean] saturday
36
+ attr_accessor :saturday
37
+
38
+ # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
39
+ attr_accessor :unknown_json_fields
40
+
41
+ def initialize
42
+ clear
43
+ end
44
+
45
+ def clear
46
+ @unknown_json_fields = {}
47
+ end
48
+
49
+ # @param [String] json_string The complete object in JSON format
50
+ def from_json(json_string)
51
+ raise TypeError, "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
52
+
53
+ from_hash(JSON.parse(json_string))
54
+ end
55
+
56
+ # @param [Hash] obj The complete object as a Ruby hash
57
+ def from_hash(obj)
58
+ raise TypeError, "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
59
+
60
+ obj.each do |k, v|
61
+ case k
62
+ when 'Sunday'
63
+ @sunday = v
64
+ when 'Monday'
65
+ @monday = v
66
+ when 'Tuesday'
67
+ @tuesday = v
68
+ when 'Wednesday'
69
+ @wednesday = v
70
+ when 'Thursday'
71
+ @thursday = v
72
+ when 'Friday'
73
+ @friday = v
74
+ when 'Saturday'
75
+ @saturday = v
76
+ else
77
+ @unknown_json_fields[k] = v
78
+ end
79
+ end
80
+ end
81
+
82
+ # @return [Hash] The complete object as a Ruby hash
83
+ def to_hash
84
+ ret = {}
85
+ ret['Sunday'] = @sunday
86
+ ret['Monday'] = @monday
87
+ ret['Tuesday'] = @tuesday
88
+ ret['Wednesday'] = @wednesday
89
+ ret['Thursday'] = @thursday
90
+ ret['Friday'] = @friday
91
+ ret['Saturday'] = @saturday
92
+ @unknown_json_fields.each do |k, v|
93
+ ret[k] = v
94
+ end
95
+ ret
96
+ end
97
+
98
+ # @return [Hash] The complete object as a Ruby hash
99
+ def to_h
100
+ to_hash
101
+ end
102
+
103
+ # @return [String] The complete object as a JSON string
104
+ def to_json(options = {})
105
+ to_hash.to_json(options)
106
+ end
107
+ end
108
+ end
@@ -0,0 +1,84 @@
1
+ #!/usr/bin/env ruby --enable-frozen-string-literal
2
+ #
3
+ # Copyright (c) 2020-2022 Comet Licensing Ltd.
4
+ # Please see the LICENSE file for usage information.
5
+ #
6
+ # SPDX-License-Identifier: MIT
7
+ #
8
+ # frozen_string_literal: true
9
+
10
+ require 'json'
11
+
12
+ module Comet
13
+
14
+ # HourSchedConfig is a typed class wrapper around the underlying Comet Server API data structure.
15
+ class HourSchedConfig
16
+
17
+ # @type [Number] hour
18
+ attr_accessor :hour
19
+
20
+ # @type [Number] minutes
21
+ attr_accessor :minutes
22
+
23
+ # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
24
+ attr_accessor :unknown_json_fields
25
+
26
+ def initialize
27
+ clear
28
+ end
29
+
30
+ def clear
31
+ @hour = 0
32
+ @minutes = 0
33
+ @unknown_json_fields = {}
34
+ end
35
+
36
+ # @param [String] json_string The complete object in JSON format
37
+ def from_json(json_string)
38
+ raise TypeError, "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
39
+
40
+ from_hash(JSON.parse(json_string))
41
+ end
42
+
43
+ # @param [Hash] obj The complete object as a Ruby hash
44
+ def from_hash(obj)
45
+ raise TypeError, "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
46
+
47
+ obj.each do |k, v|
48
+ case k
49
+ when 'Hour'
50
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
51
+
52
+ @hour = v
53
+ when 'Minutes'
54
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
55
+
56
+ @minutes = v
57
+ else
58
+ @unknown_json_fields[k] = v
59
+ end
60
+ end
61
+ end
62
+
63
+ # @return [Hash] The complete object as a Ruby hash
64
+ def to_hash
65
+ ret = {}
66
+ ret['Hour'] = @hour
67
+ ret['Minutes'] = @minutes
68
+ @unknown_json_fields.each do |k, v|
69
+ ret[k] = v
70
+ end
71
+ ret
72
+ end
73
+
74
+ # @return [Hash] The complete object as a Ruby hash
75
+ def to_h
76
+ to_hash
77
+ end
78
+
79
+ # @return [String] The complete object as a JSON string
80
+ def to_json(options = {})
81
+ to_hash.to_json(options)
82
+ end
83
+ end
84
+ end
@@ -12,6 +12,7 @@ require 'json'
12
12
  module Comet
13
13
 
14
14
  # JobEntry is a typed class wrapper around the underlying Comet Server API data structure.
15
+ # JobEntry is a single entry within a job report.
15
16
  class JobEntry
16
17
 
17
18
  # @type [Number] time
@@ -17,6 +17,9 @@ module Comet
17
17
  # @type [Number] level
18
18
  attr_accessor :level
19
19
 
20
+ # @type [Boolean] sign_locally
21
+ attr_accessor :sign_locally
22
+
20
23
  # @type [Comet::SSHConnection] sshserver
21
24
  attr_accessor :sshserver
22
25
 
@@ -35,6 +38,27 @@ module Comet
35
38
  # @type [Number] apple_idpass_format
36
39
  attr_accessor :apple_idpass_format
37
40
 
41
+ # @type [String] certificate_file
42
+ attr_accessor :certificate_file
43
+
44
+ # @type [String] app_certificate_file
45
+ attr_accessor :app_certificate_file
46
+
47
+ # @type [String] pfx_file_password
48
+ attr_accessor :pfx_file_password
49
+
50
+ # @type [Number] pfx_file_password_format
51
+ attr_accessor :pfx_file_password_format
52
+
53
+ # @type [String] notary_apiissuer_id
54
+ attr_accessor :notary_apiissuer_id
55
+
56
+ # @type [String] notary_apikey_id
57
+ attr_accessor :notary_apikey_id
58
+
59
+ # @type [String] notary_apikey_file
60
+ attr_accessor :notary_apikey_file
61
+
38
62
  # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
39
63
  attr_accessor :unknown_json_fields
40
64
 
@@ -50,6 +74,13 @@ module Comet
50
74
  @apple_id = ''
51
75
  @apple_idpass = ''
52
76
  @apple_idpass_format = 0
77
+ @certificate_file = ''
78
+ @app_certificate_file = ''
79
+ @pfx_file_password = ''
80
+ @pfx_file_password_format = 0
81
+ @notary_apiissuer_id = ''
82
+ @notary_apikey_id = ''
83
+ @notary_apikey_file = ''
53
84
  @unknown_json_fields = {}
54
85
  end
55
86
 
@@ -70,6 +101,8 @@ module Comet
70
101
  raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
71
102
 
72
103
  @level = v
104
+ when 'SignLocally'
105
+ @sign_locally = v
73
106
  when 'SSHServer'
74
107
  @sshserver = Comet::SSHConnection.new
75
108
  @sshserver.from_hash(v)
@@ -93,6 +126,34 @@ module Comet
93
126
  raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
94
127
 
95
128
  @apple_idpass_format = v
129
+ when 'CertificateFile'
130
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
131
+
132
+ @certificate_file = v
133
+ when 'AppCertificateFile'
134
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
135
+
136
+ @app_certificate_file = v
137
+ when 'PfxFilePassword'
138
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
139
+
140
+ @pfx_file_password = v
141
+ when 'PfxFilePasswordFormat'
142
+ raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
143
+
144
+ @pfx_file_password_format = v
145
+ when 'NotaryAPIIssuerID'
146
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
147
+
148
+ @notary_apiissuer_id = v
149
+ when 'NotaryAPIKeyID'
150
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
151
+
152
+ @notary_apikey_id = v
153
+ when 'NotaryAPIKeyFile'
154
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
155
+
156
+ @notary_apikey_file = v
96
157
  else
97
158
  @unknown_json_fields[k] = v
98
159
  end
@@ -103,12 +164,20 @@ module Comet
103
164
  def to_hash
104
165
  ret = {}
105
166
  ret['Level'] = @level
167
+ ret['SignLocally'] = @sign_locally
106
168
  ret['SSHServer'] = @sshserver
107
169
  ret['CertificateName'] = @certificate_name
108
170
  ret['AppCertificateName'] = @app_certificate_name
109
171
  ret['AppleID'] = @apple_id
110
172
  ret['AppleIDPass'] = @apple_idpass
111
173
  ret['AppleIDPassFormat'] = @apple_idpass_format
174
+ ret['CertificateFile'] = @certificate_file
175
+ ret['AppCertificateFile'] = @app_certificate_file
176
+ ret['PfxFilePassword'] = @pfx_file_password
177
+ ret['PfxFilePasswordFormat'] = @pfx_file_password_format
178
+ ret['NotaryAPIIssuerID'] = @notary_apiissuer_id
179
+ ret['NotaryAPIKeyID'] = @notary_apikey_id
180
+ ret['NotaryAPIKeyFile'] = @notary_apikey_file
112
181
  @unknown_json_fields.each do |k, v|
113
182
  ret[k] = v
114
183
  end
@@ -32,6 +32,9 @@ module Comet
32
32
  # @type [String] path_header_image
33
33
  attr_accessor :path_header_image
34
34
 
35
+ # @type [String] path_app_icon_image
36
+ attr_accessor :path_app_icon_image
37
+
35
38
  # @type [String] package_identifier
36
39
  attr_accessor :package_identifier
37
40
 
@@ -79,6 +82,7 @@ module Comet
79
82
  @path_eula_rtf = ''
80
83
  @path_tile_png = ''
81
84
  @path_header_image = ''
85
+ @path_app_icon_image = ''
82
86
  @package_identifier = ''
83
87
  @windows_code_sign_pkcs12file_path = ''
84
88
  @windows_code_sign_pkcs12password_format = 0
@@ -130,6 +134,10 @@ module Comet
130
134
  raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
131
135
 
132
136
  @path_header_image = v
137
+ when 'PathAppIconImage'
138
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
139
+
140
+ @path_app_icon_image = v
133
141
  when 'PackageIdentifier'
134
142
  raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
135
143
 
@@ -188,6 +196,7 @@ module Comet
188
196
  ret['PathEulaRtf'] = @path_eula_rtf
189
197
  ret['PathTilePng'] = @path_tile_png
190
198
  ret['PathHeaderImage'] = @path_header_image
199
+ ret['PathAppIconImage'] = @path_app_icon_image
191
200
  ret['PackageIdentifier'] = @package_identifier
192
201
  ret['WindowsCodeSignPKCS12FilePath'] = @windows_code_sign_pkcs12file_path
193
202
  ret['WindowsCodeSignPKCS12PasswordFormat'] = @windows_code_sign_pkcs12password_format
@@ -41,6 +41,13 @@ module Comet
41
41
  # @type [Comet::CustomRemoteBucketSettings] custom
42
42
  attr_accessor :custom
43
43
 
44
+ # @type [Comet::S3GenericVirtualStorageRole] s3
45
+ attr_accessor :s3
46
+
47
+ # Amazon AWS - Virtual Storage Role
48
+ # @type [Comet::AmazonAWSVirtualStorageRoleSettings] aws
49
+ attr_accessor :aws
50
+
44
51
  # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
45
52
  attr_accessor :unknown_json_fields
46
53
 
@@ -58,6 +65,8 @@ module Comet
58
65
  @b2 = Comet::B2VirtualStorageRoleSettings.new
59
66
  @wasabi = Comet::WasabiVirtualStorageRoleSettings.new
60
67
  @custom = Comet::CustomRemoteBucketSettings.new
68
+ @s3 = Comet::S3GenericVirtualStorageRole.new
69
+ @aws = Comet::AmazonAWSVirtualStorageRoleSettings.new
61
70
  @unknown_json_fields = {}
62
71
  end
63
72
 
@@ -106,6 +115,12 @@ module Comet
106
115
  when 'Custom'
107
116
  @custom = Comet::CustomRemoteBucketSettings.new
108
117
  @custom.from_hash(v)
118
+ when 'S3'
119
+ @s3 = Comet::S3GenericVirtualStorageRole.new
120
+ @s3.from_hash(v)
121
+ when 'AWS'
122
+ @aws = Comet::AmazonAWSVirtualStorageRoleSettings.new
123
+ @aws.from_hash(v)
109
124
  else
110
125
  @unknown_json_fields[k] = v
111
126
  end
@@ -138,6 +153,12 @@ module Comet
138
153
  unless @custom.nil?
139
154
  ret['Custom'] = @custom
140
155
  end
156
+ unless @s3.nil?
157
+ ret['S3'] = @s3
158
+ end
159
+ unless @aws.nil?
160
+ ret['AWS'] = @aws
161
+ end
141
162
  @unknown_json_fields.each do |k, v|
142
163
  ret[k] = v
143
164
  end
@@ -41,6 +41,13 @@ module Comet
41
41
  # @type [Comet::CustomRemoteBucketSettings] custom
42
42
  attr_accessor :custom
43
43
 
44
+ # @type [Comet::S3GenericVirtualStorageRole] s3
45
+ attr_accessor :s3
46
+
47
+ # Amazon AWS - Virtual Storage Role
48
+ # @type [Comet::AmazonAWSVirtualStorageRoleSettings] aws
49
+ attr_accessor :aws
50
+
44
51
  # @type [Boolean] storage_limit_enabled
45
52
  attr_accessor :storage_limit_enabled
46
53
 
@@ -67,6 +74,8 @@ module Comet
67
74
  @b2 = Comet::B2VirtualStorageRoleSettings.new
68
75
  @wasabi = Comet::WasabiVirtualStorageRoleSettings.new
69
76
  @custom = Comet::CustomRemoteBucketSettings.new
77
+ @s3 = Comet::S3GenericVirtualStorageRole.new
78
+ @aws = Comet::AmazonAWSVirtualStorageRoleSettings.new
70
79
  @storage_limit_bytes = 0
71
80
  @unknown_json_fields = {}
72
81
  end
@@ -116,6 +125,12 @@ module Comet
116
125
  when 'Custom'
117
126
  @custom = Comet::CustomRemoteBucketSettings.new
118
127
  @custom.from_hash(v)
128
+ when 'S3'
129
+ @s3 = Comet::S3GenericVirtualStorageRole.new
130
+ @s3.from_hash(v)
131
+ when 'AWS'
132
+ @aws = Comet::AmazonAWSVirtualStorageRoleSettings.new
133
+ @aws.from_hash(v)
119
134
  when 'StorageLimitEnabled'
120
135
  @storage_limit_enabled = v
121
136
  when 'StorageLimitBytes'
@@ -156,6 +171,12 @@ module Comet
156
171
  unless @custom.nil?
157
172
  ret['Custom'] = @custom
158
173
  end
174
+ unless @s3.nil?
175
+ ret['S3'] = @s3
176
+ end
177
+ unless @aws.nil?
178
+ ret['AWS'] = @aws
179
+ end
159
180
  ret['StorageLimitEnabled'] = @storage_limit_enabled
160
181
  ret['StorageLimitBytes'] = @storage_limit_bytes
161
182
  ret['RebrandStorage'] = @rebrand_storage
@@ -0,0 +1,111 @@
1
+ #!/usr/bin/env ruby --enable-frozen-string-literal
2
+ #
3
+ # Copyright (c) 2020-2022 Comet Licensing Ltd.
4
+ # Please see the LICENSE file for usage information.
5
+ #
6
+ # SPDX-License-Identifier: MIT
7
+ #
8
+ # frozen_string_literal: true
9
+
10
+ require 'json'
11
+
12
+ module Comet
13
+
14
+ # S3GenericVirtualStorageRole is a typed class wrapper around the underlying Comet Server API data structure.
15
+ class S3GenericVirtualStorageRole
16
+
17
+ # @type [String] s3endpoint
18
+ attr_accessor :s3endpoint
19
+
20
+ # @type [String] iamendpoint
21
+ attr_accessor :iamendpoint
22
+
23
+ # @type [String] master_bucket
24
+ attr_accessor :master_bucket
25
+
26
+ # @type [String] access_key
27
+ attr_accessor :access_key
28
+
29
+ # @type [String] secret_key
30
+ attr_accessor :secret_key
31
+
32
+ # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
33
+ attr_accessor :unknown_json_fields
34
+
35
+ def initialize
36
+ clear
37
+ end
38
+
39
+ def clear
40
+ @s3endpoint = ''
41
+ @iamendpoint = ''
42
+ @master_bucket = ''
43
+ @access_key = ''
44
+ @secret_key = ''
45
+ @unknown_json_fields = {}
46
+ end
47
+
48
+ # @param [String] json_string The complete object in JSON format
49
+ def from_json(json_string)
50
+ raise TypeError, "'json_string' expected String, got #{json_string.class}" unless json_string.is_a? String
51
+
52
+ from_hash(JSON.parse(json_string))
53
+ end
54
+
55
+ # @param [Hash] obj The complete object as a Ruby hash
56
+ def from_hash(obj)
57
+ raise TypeError, "'obj' expected Hash, got #{obj.class}" unless obj.is_a? Hash
58
+
59
+ obj.each do |k, v|
60
+ case k
61
+ when 'S3Endpoint'
62
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
63
+
64
+ @s3endpoint = v
65
+ when 'IAMEndpoint'
66
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
67
+
68
+ @iamendpoint = v
69
+ when 'MasterBucket'
70
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
71
+
72
+ @master_bucket = v
73
+ when 'AccessKey'
74
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
75
+
76
+ @access_key = v
77
+ when 'SecretKey'
78
+ raise TypeError, "'v' expected String, got #{v.class}" unless v.is_a? String
79
+
80
+ @secret_key = v
81
+ else
82
+ @unknown_json_fields[k] = v
83
+ end
84
+ end
85
+ end
86
+
87
+ # @return [Hash] The complete object as a Ruby hash
88
+ def to_hash
89
+ ret = {}
90
+ ret['S3Endpoint'] = @s3endpoint
91
+ ret['IAMEndpoint'] = @iamendpoint
92
+ ret['MasterBucket'] = @master_bucket
93
+ ret['AccessKey'] = @access_key
94
+ ret['SecretKey'] = @secret_key
95
+ @unknown_json_fields.each do |k, v|
96
+ ret[k] = v
97
+ end
98
+ ret
99
+ end
100
+
101
+ # @return [Hash] The complete object as a Ruby hash
102
+ def to_h
103
+ to_hash
104
+ end
105
+
106
+ # @return [String] The complete object as a JSON string
107
+ def to_json(options = {})
108
+ to_hash.to_json(options)
109
+ end
110
+ end
111
+ end
@@ -23,6 +23,21 @@ module Comet
23
23
  # @type [Number] offset
24
24
  attr_accessor :offset
25
25
 
26
+ # @type [Boolean] restrict_runtime
27
+ attr_accessor :restrict_runtime
28
+
29
+ # @type [Comet::HourSchedConfig] from_time
30
+ attr_accessor :from_time
31
+
32
+ # @type [Comet::HourSchedConfig] to_time
33
+ attr_accessor :to_time
34
+
35
+ # @type [Boolean] restrict_days
36
+ attr_accessor :restrict_days
37
+
38
+ # @type [Comet::DaysOfWeekConfig] days_select
39
+ attr_accessor :days_select
40
+
26
41
  # @type [Hash] Hidden storage to preserve future properties for non-destructive roundtrip operations
27
42
  attr_accessor :unknown_json_fields
28
43
 
@@ -34,6 +49,9 @@ module Comet
34
49
  @frequency_type = 0
35
50
  @seconds_past = 0
36
51
  @offset = 0
52
+ @from_time = Comet::HourSchedConfig.new
53
+ @to_time = Comet::HourSchedConfig.new
54
+ @days_select = Comet::DaysOfWeekConfig.new
37
55
  @unknown_json_fields = {}
38
56
  end
39
57
 
@@ -62,6 +80,19 @@ module Comet
62
80
  raise TypeError, "'v' expected Numeric, got #{v.class}" unless v.is_a? Numeric
63
81
 
64
82
  @offset = v
83
+ when 'RestrictRuntime'
84
+ @restrict_runtime = v
85
+ when 'FromTime'
86
+ @from_time = Comet::HourSchedConfig.new
87
+ @from_time.from_hash(v)
88
+ when 'ToTime'
89
+ @to_time = Comet::HourSchedConfig.new
90
+ @to_time.from_hash(v)
91
+ when 'RestrictDays'
92
+ @restrict_days = v
93
+ when 'DaysSelect'
94
+ @days_select = Comet::DaysOfWeekConfig.new
95
+ @days_select.from_hash(v)
65
96
  else
66
97
  @unknown_json_fields[k] = v
67
98
  end
@@ -76,6 +107,11 @@ module Comet
76
107
  unless @offset.nil?
77
108
  ret['Offset'] = @offset
78
109
  end
110
+ ret['RestrictRuntime'] = @restrict_runtime
111
+ ret['FromTime'] = @from_time
112
+ ret['ToTime'] = @to_time
113
+ ret['RestrictDays'] = @restrict_days
114
+ ret['DaysSelect'] = @days_select
79
115
  @unknown_json_fields.each do |k, v|
80
116
  ret[k] = v
81
117
  end
@@ -20,6 +20,7 @@ module Comet
20
20
  # @type [Number] modify_time
21
21
  attr_accessor :modify_time
22
22
 
23
+ # One of the STOREDOBJECTTYPE_... constant values
23
24
  # @type [String] type
24
25
  attr_accessor :type
25
26