Revision b0ddfd38 src/oca/ruby/OpenNebula/Pool.rb

View differences:

src/oca/ruby/OpenNebula/Pool.rb
173 173
            return rc
174 174
        end
175 175

  
176
        # Calls to the corresponding chown method to modify
177
        # the object's owner and group
178
        # xml_method:: _String_ the name of the XML-RPC method
179
        # uid:: _Integer_ the new owner id. Set to -1 to leave the current one
180
        # gid:: _Integer_ the new group id. Set to -1 to leave the current one
181
        # [return] nil in case of success or an Error object
182
        def chown(xml_method, uid, gid)
183
            return Error.new('ID not defined') if !@pe_id
184

  
185
            rc = @client.call(xml_method,@pe_id, uid, gid)
186
            rc = nil if !OpenNebula.is_error?(rc)
187

  
188
            return rc
189
        end
190

  
176 191
    public
177 192

  
178 193
        # Creates new element specifying its id

Also available in: Unified diff