Class: OpenfireAdmin::Plugin
- Inherits:
-
Object
- Object
- OpenfireAdmin::Plugin
- Defined in:
- lib/openfire_admin/plugin.rb
Overview
plugin abstract class
Direct Known Subclasses
Instance Attribute Summary collapse
-
#description ⇒ Object
Returns the value of attribute description.
-
#key ⇒ Object
readonly
Returns the value of attribute key.
-
#name ⇒ Object
Returns the value of attribute name.
-
#version ⇒ Object
Returns the value of attribute version.
Instance Method Summary collapse
- #eql?(obj) ⇒ Boolean
-
#initialize(client, key) ⇒ Plugin
constructor
A new instance of Plugin.
- #inspect ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(client, key) ⇒ Plugin
Returns a new instance of Plugin.
49 50 51 52 |
# File 'lib/openfire_admin/plugin.rb', line 49 def initialize(client, key) @client = client @key = key.downcase end |
Instance Attribute Details
#description ⇒ Object
Returns the value of attribute description.
47 48 49 |
# File 'lib/openfire_admin/plugin.rb', line 47 def description @description end |
#key ⇒ Object (readonly)
Returns the value of attribute key.
48 49 50 |
# File 'lib/openfire_admin/plugin.rb', line 48 def key @key end |
#name ⇒ Object
Returns the value of attribute name.
47 48 49 |
# File 'lib/openfire_admin/plugin.rb', line 47 def name @name end |
#version ⇒ Object
Returns the value of attribute version.
47 48 49 |
# File 'lib/openfire_admin/plugin.rb', line 47 def version @version end |
Instance Method Details
#eql?(obj) ⇒ Boolean
59 60 61 62 63 64 65 66 67 68 |
# File 'lib/openfire_admin/plugin.rb', line 59 def eql?(obj) case obj when Plugin self.key == obj.key when String self.key == obj.downcase else false end end |
#inspect ⇒ Object
53 54 55 |
# File 'lib/openfire_admin/plugin.rb', line 53 def inspect to_s end |
#to_s ⇒ Object
56 57 58 |
# File 'lib/openfire_admin/plugin.rb', line 56 def to_s "#<#{self.class} #{key} #{version} (#{name.inspect} #{description.inspect})>" end |