You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -152,7 +152,7 @@ let optionalString = fileWrapper.string()
152
152
### Updating Contents
153
153
> **_Notice:_** File wrappers only.
154
154
155
-
To update the contents of a regular file wrapper use `-updateContent`.
155
+
To update the contents of a regular file wrapper use `-updateContent`, named `update(newContent:)` in Swift.
156
156
```objective-c
157
157
LSFileWrapper* fileWrapper;
158
158
@@ -168,7 +168,7 @@ fileWrapper.update(newContent: "Hello, World!" as NSString)
168
168
### Removing wrappers
169
169
> **_Notice:_** Directory wrappers only.
170
170
171
-
To remove a file wrapper from existing wrapper use `-removeFileWrapper`.
171
+
To remove a file wrapper from existing wrapper use `-removeFileWrapper` or `removeFileWrapperWithPath`, named `removeWrapper()` or `removeWrapper(with:)` in Swift.
172
172
```objective-c
173
173
LSFileWrapper* directoryWrapper;
174
174
@@ -187,17 +187,17 @@ if (wrapperToRemove) {
187
187
let directoryWrapper: LSFileWrapper
188
188
189
189
// Using a path, can also contain "/" for subfolder search, all children can be removed
if let wrapperToRemove = directoryWrapper.wrapper(with: "hello.txt") {
194
+
directoryWrapper.removeWrapper(wrapperToRemove)
195
195
}
196
196
```
197
197
### Getting child wrappers
198
198
> **_Notice:_** Directory wrappers only.
199
199
200
-
To get a wrapper from a directory wrapper call `-fileWrapperWithPath`, this will also traverse all children based on supplied path.
200
+
To get a wrapper from a directory wrapper call `-fileWrapperWithPath`, named `wrappers(with:)` in Swift, this will also traverse all children based on supplied path.
201
201
```objective-c
202
202
LSFileWrapper* directoryWrapper;
203
203
@@ -211,7 +211,7 @@ let directoryWrapper: LSFileWrapper
211
211
let wrapper = directoryWrapper.wrapper(with: "hello.txt")
212
212
```
213
213
214
-
To get all first-degree child wrappers from a directory wrapper call `-fileWrappersInPath`, this will also traverse all children based on supplied path.
214
+
To get all first-degree child wrappers from a directory wrapper call `-fileWrappersInPath`, named `wrappers(in:)` in Swift, this will also traverse all children based on supplied path.
0 commit comments