class Apcera::Rule
Attributes
action[RW]
created_at[RW]
created_by[RW]
fqn[RW]
job[RW]
provider[RW]
service[RW]
type[RW]
version_id[RW]
Public Class Methods
attribute_map()
click to toggle source
attribute mapping from ruby-style variable name to JSON key
# File lib/apcera/models/rule.rb, line 6 def self.attribute_map { # The type of action to take when the rule is triggered. Can either by 'hook' or 'notification'. :'action' => :'action', # UNIX timestamp when event rule was created. :'created_at' => :'created_at', # Principal name of user who created the event rule. :'created_by' => :'created_by', # The rule's fully-qualified name against which policy may be enforced. :'fqn' => :'fqn', # FQN of the job to enforce the rule against. :'job' => :'job', # FQN of the provider to enforce this rule against. In only `provider` is populated for this rule, then all semantic pipelines consuming a provider matching this FQN will have the rule enforced against them. :'provider' => :'provider', # FQN of the service to enforce this rule against. If only `service` is populated for this rule, then all semantic pipelines consuming a service matching this FQN will have the rule enforced against them. :'service' => :'service', # Type depends upon specified `action` of event rule, and can specify the timing of the hook firing. :'type' => :'type', # Rule's auto-incremented version number. :'version_id' => :'version_id' } end
new(attributes = {})
click to toggle source
# File lib/apcera/models/rule.rb, line 55 def initialize(attributes = {}) return if !attributes.is_a?(Hash) || attributes.empty? # convert string to symbol for hash key attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo} if attributes[:'action'] self.action = attributes[:'action'] end if attributes[:'created_at'] self.created_at = attributes[:'created_at'] end if attributes[:'created_by'] self.created_by = attributes[:'created_by'] end if attributes[:'fqn'] self.fqn = attributes[:'fqn'] end if attributes[:'job'] self.job = attributes[:'job'] end if attributes[:'provider'] self.provider = attributes[:'provider'] end if attributes[:'service'] self.service = attributes[:'service'] end if attributes[:'type'] self.type = attributes[:'type'] end if attributes[:'version_id'] self.version_id = attributes[:'version_id'] end end
swagger_types()
click to toggle source
attribute type
# File lib/apcera/models/rule.rb, line 40 def self.swagger_types { :'action' => :'String', :'created_at' => :'Float', :'created_by' => :'String', :'fqn' => :'String', :'job' => :'String', :'provider' => :'String', :'service' => :'String', :'type' => :'String', :'version_id' => :'Integer' } end