-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
140 additions
and
124 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "anime-grubber" | ||
version = "0.0.5" | ||
version = "0.0.6" | ||
edition = "2021" | ||
authors = ["TOwInOK <[email protected]>"] | ||
description = "A convenient library for extracting images of cute characters from websites." | ||
|
@@ -16,6 +16,7 @@ categories = ["api-bindings", "web-programming"] | |
async-trait = "0.1.83" | ||
miniserde = "0.1.40" | ||
reqwest = "0.12.8" | ||
smallvec = "1.13.2" | ||
thiserror = "1.0.64" | ||
tracing = "0.1.40" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
//! # Implementing New Agents | ||
//! | ||
//! To implement a new agent, you need to: | ||
//! 1. Create a new agent type | ||
//! 2. Implement required traits | ||
//! 3. Create a public constructor function | ||
//! | ||
//! ## Example Implementation | ||
//! | ||
//! ```no_compile | ||
//! // 1. Define your agent type | ||
//! pub struct MyNewAgent; | ||
//! | ||
//! // 2. Implement required traits | ||
//! impl SimpleAgent for MyNewAgent { | ||
//! fn builder(self) -> AgentBuilder<Simple> { | ||
//! AgentBuilder::new() | ||
//! } | ||
//! } | ||
//! | ||
//! // Optionally implement TaggedAgent if your source supports tags | ||
//! impl TaggedAgent for MyNewAgent { | ||
//! fn tagged_builder(self) -> AgentBuilder<Tagged> { | ||
//! AgentBuilder::new() | ||
//! } | ||
//! } | ||
//! | ||
//! // 3. Create a public constructor | ||
//! pub fn my_new_agent() -> MyNewAgent { | ||
//! MyNewAgent | ||
//! } | ||
//! ``` | ||
use crate::{Agent, Result}; | ||
use std::marker::PhantomData; | ||
|
||
// Маркерные типы для билдера | ||
pub struct Simple; | ||
pub struct Tagged; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.