gildedhonour / atarashii_imap Goto Github PK
View Code? Open in Web Editor NEW新しい IMAP client in Rust
License: Apache License 2.0
新しい IMAP client in Rust
License: Apache License 2.0
The API often asks for owned String
objects when a string slice (&str
) would suffice. Accepting string slices will significantly reduce allocations.
Right now the responses are a Vec
of String
s. It'd be nice if each response was it's own type/enum variant, i.e. ListResponse
for the LIST command.
When accepting references to stringy types, it can be useful to accept a generic S: AsRef<T>
where T
is the target stringy type (e.g., str
). For example:
fn my_fn<S: AsRef<str>>(my_name: S) {
let my_name: &str = my_name.as_ref();
println!("{}", my_name);
}
Can be called with owned String
s, &str
s, or any other custom string-like type that implements AsRef<str>
.
Can you make module error
public public please? Because we can't use it with error_chain
error[E0433]: failed to resolve. Use of undeclared type or module `ssl`
--> atarashii_imap/src/lib.rs:68:12
|
68 | StartTls(ssl::SslStream<TcpStream>),
| ^^^^^^^^^^^^^^^^^^^^^^^^^ Use of undeclared type or module `ssl`
error[E0433]: failed to resolve. Use of undeclared type or module `ssl`
--> atarashii_imap/src/lib.rs:69:10
|
69 | SslTls(ssl::SslStream<TcpStream>)
| ^^^^^^^^^^^^^^^^^^^^^^^^^ Use of undeclared type or module `ssl`
error[E0433]: failed to resolve. Use of undeclared type or module `TslConnectorBuilder`
--> atarashii_imap/src/lib.rs:234:25
|
234 | let connector = TslConnectorBuilder::new(SslMethod::tls()).unwrap().build();
| ^^^^^^^^^^^^^^^^^^^^^^^^ Use of undeclared type or module `TslConnectorBuilder`
error[E0433]: failed to resolve. Use of undeclared type or module `SslMethod`
--> atarashii_imap/src/lib.rs:234:50
|
234 | let connector = TslConnectorBuilder::new(SslMethod::tls()).unwrap().build();
| ^^^^^^^^^^^^^^ Use of undeclared type or module `SslMethod`
error[E0433]: failed to resolve. Use of undeclared type or module `ssl`
--> atarashii_imap/src/lib.rs:248:38
|
248 | fn verify_greeting(stcp_conn: &mut ssl::SslStream<TcpStream>) -> () {
| ^^^^^^^^^^^^^^^^^^^^^^^^^ Use of undeclared type or module `ssl`
error: aborting due to previous error(s)
error: Could not compile `atarashii_imap`.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.