Class: Megam::Mixins::Operations

Inherits:
Object
  • Object
show all
Includes:
Nilavu::MegamAttributes
Defined in:
lib/megam/mixins/components.rb

Constant Summary collapse

ATTRIBUTES =
[]
CI =
'CI'.freeze
CI_DESCRIPTON =
'always up to date code. sweet.'
BIND =
'bind'.freeze
BIND_DESCRIPTON =
'bind. sweet.'

Constants included from Nilavu::MegamAttributes

Nilavu::MegamAttributes::KEY, Nilavu::MegamAttributes::VALUE

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Nilavu::MegamAttributes

#set_attributes, #to_hash

Constructor Details

#initialize(params, type, desc) ⇒ Operations

Returns a new instance of Operations.



103
104
105
106
107
108
# File 'lib/megam/mixins/components.rb', line 103

def initialize(params, type, desc)
  @type = type
  @desc = desc
  # set_attributes(params)
  @prop = prop(params)
end

Instance Attribute Details

#desc ⇒ Object (readonly)

Returns the value of attribute desc.



94
95
96
# File 'lib/megam/mixins/components.rb', line 94

def desc
  @desc
end

#prop(params) ⇒ Object (readonly)

Key_name mismatch. Key_name is to be changed.



122
123
124
# File 'lib/megam/mixins/components.rb', line 122

def prop
  @prop
end

#type ⇒ Object (readonly)

Returns the value of attribute type.



94
95
96
# File 'lib/megam/mixins/components.rb', line 94

def type
  @type
end

Instance Method Details

#attributes ⇒ Object



110
111
112
# File 'lib/megam/mixins/components.rb', line 110

def attributes
  ATTRIBUTES
end

#tohash ⇒ Object



114
115
116
117
118
119
# File 'lib/megam/mixins/components.rb', line 114

def tohash
  {   operation_type: @type,
      description: @desc,
      properties: @prop
  }
end