RafaelEstevam.Simple.Spider 0.7.501

A simple to use and modular spider for web crawling with an example rich GitHub repository
(work in progress)

Install-Package RafaelEstevam.Simple.Spider -Version 0.7.501
dotnet add package RafaelEstevam.Simple.Spider --version 0.7.501
<PackageReference Include="RafaelEstevam.Simple.Spider" Version="0.7.501" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add RafaelEstevam.Simple.Spider --version 0.7.501
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Simple.Spider

A simple and modular web spider written in C# .Net

  • Core 3.1
  • Net 5.0

.NET Core
The MIT License

This Package was moved from [Net.RafaelEstevam.Spider.Simple.Lib]

Content

Some advantages

  • Very simple to use and operate, ideal for lots of small projects or personal ones
  • Easy html filter with HObject (a HtmlNode wrap with use similar to JObject)
  • Internal conversion from html to XElement, no need to external tools on use
  • Automatic Json parser to JObject
  • Automatic Json deserialize <T>
  • Modular Parser engine (you can add your own parsers!)
    • JSON and XML already included
  • Modular Caching engine (you can add your own!)
    • Stand alone Cache engine included, no need to external softwares
  • Modular Downloader engine (you can add your own!)
    • WebClient with cookies or HttpClient download engine included

Easy import with NuGet

Getting started

  1. Start a new console project and add Nuget Reference
  2. PM> Install-Package Net.RafaelEstevam.Spider.Simple.Lib
  3. Create a class for your spider (or leave in program)
  4. create a new instance of SimpleSpider
    1. Give it a name, cache and log will be saved with that name
    2. Give it a domain (your spider will not fleet from it)
  5. Add a event FetchCompleted to
  6. Optionally give a first page with AddPage. If omitted, it will use the home page of the domain
  7. Call Execute()
void run()
{
    var spider = new SimpleSpider("QuotesToScrape", new Uri("http://quotes.toscrape.com/"));
    // Set the completed event to implement your stuff
    spider.FetchCompleted += fetchCompleted_items;
    // execute
    spider.Execute();
}
void fetchCompleted_items(object Sender, FetchCompleteEventArgs args)
{
    // walk around ...
    // TIP: inspect args to see stuff

    var hObj = args.GetHObject();
    string[] quotes = hObj["span > .text"];
}

TIP: Use the Simple.Tests project to see examples and poke around

Samples

See all samples at Simple.Tests

Simple.Spider

A simple and modular web spider written in C# .Net

  • Core 3.1
  • Net 5.0

.NET Core
The MIT License

This Package was moved from [Net.RafaelEstevam.Spider.Simple.Lib]

Content

Some advantages

  • Very simple to use and operate, ideal for lots of small projects or personal ones
  • Easy html filter with HObject (a HtmlNode wrap with use similar to JObject)
  • Internal conversion from html to XElement, no need to external tools on use
  • Automatic Json parser to JObject
  • Automatic Json deserialize <T>
  • Modular Parser engine (you can add your own parsers!)
    • JSON and XML already included
  • Modular Caching engine (you can add your own!)
    • Stand alone Cache engine included, no need to external softwares
  • Modular Downloader engine (you can add your own!)
    • WebClient with cookies or HttpClient download engine included

Easy import with NuGet

Getting started

  1. Start a new console project and add Nuget Reference
  2. PM> Install-Package Net.RafaelEstevam.Spider.Simple.Lib
  3. Create a class for your spider (or leave in program)
  4. create a new instance of SimpleSpider
    1. Give it a name, cache and log will be saved with that name
    2. Give it a domain (your spider will not fleet from it)
  5. Add a event FetchCompleted to
  6. Optionally give a first page with AddPage. If omitted, it will use the home page of the domain
  7. Call Execute()
void run()
{
    var spider = new SimpleSpider("QuotesToScrape", new Uri("http://quotes.toscrape.com/"));
    // Set the completed event to implement your stuff
    spider.FetchCompleted += fetchCompleted_items;
    // execute
    spider.Execute();
}
void fetchCompleted_items(object Sender, FetchCompleteEventArgs args)
{
    // walk around ...
    // TIP: inspect args to see stuff

    var hObj = args.GetHObject();
    string[] quotes = hObj["span > .text"];
}

TIP: Use the Simple.Tests project to see examples and poke around

Samples

See all samples at Simple.Tests

Release Notes

See examples and documentation on the GitHub page
Commit ea5d3d2

NuGet packages (1)

Showing the top 1 NuGet packages that depend on RafaelEstevam.Simple.Spider:

Package Downloads
RafaelEstevam.Simple.Spider.SqliteStorage
Sqlite-based storage engine to the SimpleSpider See examples and documentation on the GitHub page

GitHub repositories

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
0.7.501 63 12/30/2020
0.7.484 60 12/23/2020
0.7.458 134 11/30/2020
0.7.425 55 11/25/2020
0.7.400 105 11/16/2020
0.7.390 168 11/15/2020
0.7.378 50 11/13/2020