Class: LogStash::Outputs::Qingstor::RotationPolicy::Policy
- Inherits:
-
Object
- Object
- LogStash::Outputs::Qingstor::RotationPolicy::Policy
- Defined in:
- lib/logstash/outputs/qingstor/rotation_policy.rb
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#name ⇒ Object
10 11 12 |
# File 'lib/logstash/outputs/qingstor/rotation_policy.rb', line 10 def name self.class.name.split('::').last.downcase end |
#needs_periodic? ⇒ Boolean
14 15 16 |
# File 'lib/logstash/outputs/qingstor/rotation_policy.rb', line 14 def needs_periodic? true end |
#positive_check(*arg) ⇒ Object
18 19 20 21 22 23 |
# File 'lib/logstash/outputs/qingstor/rotation_policy.rb', line 18 def positive_check(*arg) arg.each do |x| raise(LogStash::ConfigurationError, "#{name} policy needs positive arguments") if x <= 0 end end |