remove method
Leave feedback
On this page
Removes the specified attributes from the specified indexed document.
def remove(self, path, attributes):
...
| Parameter | Type | Description |
|---|---|---|
| path | str |
The document path. |
| attributes | list[str] |
The attributes to remove. |
import os
from groupdocs.search import Index
from groupdocs.search.common import AttributeChangeBatch
index = Index("./index")
index.add("./documents")
batch = AttributeChangeBatch()
batch.remove(os.path.abspath("./documents/relativity-lecture.pdf"), ["main"])
index.change_attributes(batch)
Removes the specified attributes from the specified indexed documents.
def remove(self, paths, attributes):
...
| Parameter | Type | Description |
|---|---|---|
| paths | list[str] |
The documents paths. |
| attributes | list[str] |
The attributes to remove. |
These names call remove too, limited to the overloads listed.
| Alias | Accepts |
|---|---|
remove_file |
remove_file(path, attributes) |
remove_string |
remove_string(path, attributes) |
remove_files |
remove_files(path, attributes)remove_files(paths, attributes) |
remove_strings |
remove_strings(path, attributes)remove_strings(paths, attributes) |
- class
AttributeChangeBatch
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.