Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

docs: fix several typos in the documentation #1846

Merged
merged 1 commit into from
Apr 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions core/src/docs/internals/accessor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
// specific language governing permissions and limitations
// under the License.

//! The internal implement details of [`Accessor`].
//! The internal implementation details of [`Accessor`].
//!
//! [`Accessor`] is the core trait of OpenDAL's raw API. We operate
//! underlying storage services via APIs provided by [`Accessor`].
Expand Down Expand Up @@ -85,9 +85,9 @@
//! - [`Sync`]: Allow user to sync between threads without extra lock.
//! - [`Debug`][std::fmt::Debug]: Allow users to print underlying debug information of accessor.
//! - [`Unpin`]: Make sure `Accessor` can be safely moved after being pinned, so users don't need to `Pin<Box<A>>`.
//! - `'static`: Make sure `Accessor` is not a short-time reference, allow users to use `Accessor` in clouse, futures without playing with lifetime.
//! - `'static`: Make sure `Accessor` is not a short-time reference, allow users to use `Accessor` in closures and futures without playing with lifetime.
//!
//! Implementer of `Accessor` should take care the following things:
//! Implementer of `Accessor` should take care of the following things:
//!
//! - Implement `Debug` for backend, but don't leak credentials.
//! - Make sure the backend is `Send` and `Sync`, wrap the internal struct with `Arc<Mutex<T>>` if necessary.
Expand Down Expand Up @@ -202,7 +202,7 @@
//! /// async fn main() -> Result<()> {
//! /// // Create Duck backend builder.
//! /// let mut builder = Duck::default();
//! /// // Set the root for duck, all operations wilxl happen under this root.
//! /// // Set the root for duck, all operations will happen under this root.
//! /// //
//! /// // NOTE: the root must be absolute path.
//! /// builder.root("/path/to/dir");
Expand Down
12 changes: 6 additions & 6 deletions core/src/docs/internals/layer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
// specific language governing permissions and limitations
// under the License.

//! The internal implement details of [`Layer`].
//! The internal implementation details of [`Layer`].
//!
//! [`Layer`] itself is quiet simple:
//! [`Layer`] itself is quite simple:
//!
//! ```ignore
//! pub trait Layer<A: Accessor> {
Expand All @@ -27,13 +27,13 @@
//! }
//! ```
//!
//! `XxxLayer` will wrap input [`Accessor`] as inner and returns a new [`Accessor`]. So normally the implementation of [`Layer`] will be split into two parts:
//! `XxxLayer` will wrap input [`Accessor`] as inner and return a new [`Accessor`]. So normally the implementation of [`Layer`] will be split into two parts:
//!
//! - `XxxLayer` will implements [`Layer`] and return `XxxAccessor` as `Self::LayeredAccessor`.
//! - `XxxAccessor` will implements [`Accessor`] and being built by `XxxLayer`.
//! - `XxxLayer` will implement [`Layer`] and return `XxxAccessor` as `Self::LayeredAccessor`.
//! - `XxxAccessor` will implement [`Accessor`] and be built by `XxxLayer`.
//!
//! Most layer only implements part of [`Accessor`], so we provide
//! [`LayeredAccessor`] which will forward all not implemented methods to
//! [`LayeredAccessor`] which will forward all unimplemented methods to
//! `inner`. It's highly recommend to implement [`LayeredAccessor`] trait
//! instead.
//!
Expand Down