Class: Shared::Groups Abstract
- Inherits:
-
MutableCollection
- Object
- Resource
- Collection
- MutableCollection
- Shared::Groups
- Defined in:
- lib/vas/shared/groups.rb
Overview
This class is abstract.
A collection of groups
Direct Known Subclasses
Gemfire::Groups, RabbitMq::Groups, Sqlfire::Groups, TcServer::Groups, WebServer::Groups
Instance Attribute Summary
Attributes inherited from Resource
Instance Method Summary collapse
-
#create(name, nodes) ⇒ Group
Creates a new group.
-
#initialize(location, client, group_class) ⇒ Groups
constructor
A new instance of Groups.
Methods inherited from MutableCollection
Methods inherited from Collection
Constructor Details
#initialize(location, client, group_class) ⇒ Groups
Returns a new instance of Groups.
23 24 25 |
# File 'lib/vas/shared/groups.rb', line 23 def initialize(location, client, group_class) super(location, client, 'groups', group_class) end |
Instance Method Details
#create(name, nodes) ⇒ Group
Creates a new group
33 34 35 36 37 |
# File 'lib/vas/shared/groups.rb', line 33 def create(name, nodes) payload = {:name => name, :nodes => nodes.collect { |node| node.location }} super(payload, 'group') end |