This is an automated email from the ASF dual-hosted git repository.

xuanwo pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/opendal.git


The following commit(s) were added to refs/heads/main by this push:
     new 6515a4e39 chore(docs): fix docs for writer_options (#7157)
6515a4e39 is described below

commit 6515a4e394644259683ce38cecfac1fb3daf3cd9
Author: meteorgan <[email protected]>
AuthorDate: Tue Feb 3 18:07:10 2026 +0800

    chore(docs): fix docs for writer_options (#7157)
---
 core/core/src/types/operator/operator.rs | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/core/core/src/types/operator/operator.rs 
b/core/core/src/types/operator/operator.rs
index 9891652ab..45028bc11 100644
--- a/core/core/src/types/operator/operator.rs
+++ b/core/core/src/types/operator/operator.rs
@@ -923,13 +923,19 @@ impl Operator {
     /// ```
     /// # use opendal_core::Result;
     /// # use opendal_core::Operator;
+    /// # use opendal_core::options;
     /// use bytes::Bytes;
     ///
     /// # async fn test(op: Operator) -> Result<()> {
     /// let mut w = op
-    ///     .writer_with("path/to/file")
-    ///     .chunk(4 * 1024 * 1024)
-    ///     .concurrent(8)
+    ///     .writer_options(
+    ///         "path/to/file",
+    ///         options::WriteOptions {
+    ///             chunk: Some(4 * 1024 * 1024),
+    ///             concurrent: 8,
+    ///           ..Default::default()
+    ///         },
+    ///     )
     ///     .await?;
     /// w.write(vec![0; 4096]).await?;
     /// w.write(vec![1; 4096]).await?;

Reply via email to