Equivalent to ``` async fn create(&self, path: impl PathType) -> Result where Self::FileType: WritableFile; ``` Opens a file in write-only mode. This function will create a file if it does not exist, and will truncate it if it does. See [`OpenOptions`] for more details.
(&self, path: impl PathType)
| 210 | /// |
| 211 | /// See [`OpenOptions`] for more details. |
| 212 | async fn create(&self, path: impl PathType) -> Result<Self::FileType> |
| 213 | where |
| 214 | Self::FileType: WritableFile, |
| 215 | { |
| 216 | OpenOptions::new() |
| 217 | .write(true) |
| 218 | .create(true) |
| 219 | .truncate(true) |
| 220 | .open(self, path) |
| 221 | .await |
| 222 | } |
| 223 | |
| 224 | /// Equivalent to |
| 225 | /// ``` |