Sha256: 9b61988e64a7181c1697ac3581aab47e7b4f661490897a98222e441cf7701651
Contents?: true
Size: 1.27 KB
Versions: 37
Compression:
Stored size: 1.27 KB
Contents
require 'fog/openstack/models/model' module Fog module Monitoring class OpenStack class AlarmDefinition < Fog::OpenStack::Model identity :id attribute :links attribute :name attribute :description attribute :expression attribute :deterministic attribute :expression_data attribute :match_by attribute :severity attribute :actions_enabled attribute :alarm_actions attribute :ok_actions attribute :undetermined_actions def create requires :name, :expression merge_attributes( service.create_alarm_definition(attributes).body ) self end def update(attr = nil) requires :name, :expression merge_attributes( service.update_alarm_definition(id, attr || attributes).body ) end def patch(attr = nil) requires :id merge_attributes( service.patch_alarm_definition(id, attr || attributes).body ) self end def destroy requires :id service.delete_alarm_definition(id) true end def to_s name end end end end end
Version data entries
37 entries across 35 versions & 3 rubygems