Class: Hubspot::Blogs::BlogAssociation
- Inherits:
-
Hubspot::Base
- Object
- ActiveResource::Base
- Hubspot::Base
- Hubspot::Blogs::BlogAssociation
- Defined in:
- app/models/hubspot/blogs/blog_association.rb
Overview
Define an assocation base class from which blog child associations should inherit
Class Method Summary collapse
- .collection_path(prefix_options = {}, query_options = nil) ⇒ Object
- .element_path(id, prefix_options = {}, query_options = nil) ⇒ Object
Methods inherited from Hubspot::Base
Class Method Details
.collection_path(prefix_options = {}, query_options = nil) ⇒ Object
16 17 18 19 20 |
# File 'app/models/hubspot/blogs/blog_association.rb', line 16 def collection_path( = {}, = nil) , = () if .nil? raise(ActiveResource::MissingPrefixParam, ":blog_guid prefix_option is missing") unless [:blog_guid] && defined?(ActiveResource::MissingPrefixParam) "#{prefix()}#{[:blog_guid].to_s}/#{collection_name}.#{format.extension}#{query_string()}" end |
.element_path(id, prefix_options = {}, query_options = nil) ⇒ Object
11 12 13 14 |
# File 'app/models/hubspot/blogs/blog_association.rb', line 11 def element_path(id, = {}, = nil) , = () if .nil? "#{prefix()}#{collection_name}/#{URI.escape id.to_s}.#{format.extension}#{query_string()}" end |