Sha256: 36423d657e5d3062e2ff6a58c41c024e162a25bd126d1e789dd43ccf3b996fc7

Contents?: true

Size: 625 Bytes

Versions: 1

Compression:

Stored size: 625 Bytes

Contents

module Retriever
	class FetchSEO < Fetch
		def initialize(url,options)
			super
			@data = []
			page_one = Retriever::Page.new(@t.source,@t)
			@linkStack = page_one.parseInternalVisitable
			lg("URL Crawled: #{@t.target}")
			lg("#{@linkStack.size-1} new links found")

			@data.push(page_one.parseSEO)
			lg("#{@data.size} pages scraped")
			errlog("Bad URL -- #{@t.target}") if !@linkStack

			@linkStack.delete(@t.target) if @linkStack.include?(@t.target)
			@linkStack = @linkStack.take(@maxPages) if (@linkStack.size+1 > @maxPages)

			self.async_crawl_and_collect()

			@data.sort_by! {|x| x[0].length}
		end
	end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rubyretriever-1.0.0 lib/retriever/fetchseo.rb