Sha256: 0ffa4a105b555a6066b0c3215eefcf0cab2255fb4ce0cdba9392329d4399e4e9

Contents?: true

Size: 536 Bytes

Versions: 13

Compression:

Stored size: 536 Bytes

Contents

module LinkedIn
  module API
    module Companies
      def company(options={})
        selector = if options[:selector].respond_to? :each
          "::(#{options[:selector].join(',')})" 
        else
          "/#{options[:selector]}"
        end

        fields = options[:fields]
        fields_string = fields.blank? ? '' : ":(#{Permissions.render_permissions fields})"

        filter = "?#{options[:filter]}" if options[:filter].present?

        get "v1/companies#{selector}#{fields_string}#{filter}"
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
linkedin2-0.0.16 lib/linkedin/api/companies.rb
linkedin2-0.0.15 lib/linkedin/api/companies.rb
linkedin2-0.0.14 lib/linkedin/api/companies.rb
linkedin2-0.0.13 lib/linkedin/api/companies.rb
linkedin2-0.0.12 lib/linkedin/api/companies.rb
linkedin2-0.0.11 lib/linkedin/api/companies.rb
linkedin2-0.0.10 lib/linkedin/api/companies.rb
linkedin2-0.0.9 lib/linkedin/api/companies.rb
linkedin2-0.0.8 lib/linkedin/api/companies.rb
linkedin2-0.0.7 lib/linkedin/api/companies.rb
linkedin2-0.0.6 lib/linkedin/api/companies.rb
linkedin2-0.0.5 lib/linkedin/api/companies.rb
linkedin2-0.0.4 lib/linkedin/api/companies.rb