Class: RestfulSharePoint::List
- Inherits:
-
Object
- Object
- CommonBase
- Object
- RestfulSharePoint::List
- Defined in:
- lib/restful-sharepoint/objects/list.rb
Constant Summary
Constants inherited from Object
Instance Attribute Summary
Attributes inherited from Object
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Object
#fetch_deferred, #initialize, #method_missing, #properties, #properties=, #respond_to_missing?, #to_json, #values
Methods inherited from CommonBase
Constructor Details
This class inherits a constructor from RestfulSharePoint::Object
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RestfulSharePoint::Object
Class Method Details
.from_title(title, connection) ⇒ Object
4 5 6 7 8 |
# File 'lib/restful-sharepoint/objects/list.rb', line 4 def self.from_title(title, connection) new(connection: connection).tap do |list| list.define_singleton_method(:endpoint) { "/_api/web/lists/getbytitle('#{URI.encode title}')" } end end |
Instance Method Details
#endpoint ⇒ Object
10 11 12 |
# File 'lib/restful-sharepoint/objects/list.rb', line 10 def endpoint "/_api/web/lists(guid'#{@id}')" end |