Class: Cronofy::BatchResponse
- Inherits:
-
Object
- Object
- Cronofy::BatchResponse
- Defined in:
- lib/cronofy/types.rb
Defined Under Namespace
Classes: PartialSuccessError
Instance Attribute Summary collapse
-
#entries ⇒ Object
readonly
Returns the value of attribute entries.
Instance Method Summary collapse
- #errors ⇒ Object
- #errors? ⇒ Boolean
-
#initialize(entries) ⇒ BatchResponse
constructor
A new instance of BatchResponse.
Constructor Details
#initialize(entries) ⇒ BatchResponse
Returns a new instance of BatchResponse.
228 229 230 |
# File 'lib/cronofy/types.rb', line 228 def initialize(entries) @entries = entries end |
Instance Attribute Details
#entries ⇒ Object (readonly)
Returns the value of attribute entries.
226 227 228 |
# File 'lib/cronofy/types.rb', line 226 def entries @entries end |
Instance Method Details
#errors ⇒ Object
232 233 234 |
# File 'lib/cronofy/types.rb', line 232 def errors entries.select { |entry| (entry.status % 100) != 2 } end |
#errors? ⇒ Boolean
236 237 238 |
# File 'lib/cronofy/types.rb', line 236 def errors? errors.any? end |