@ThreadSafe public final class FieldSelector extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
FieldSelector.FieldFilter
This filter is designed to exclude or rename fields in a document.
|
private static class |
FieldSelector.FieldNameAndValue |
static class |
FieldSelector.FieldSelectorBuilder
A builder of a field selector.
|
private static class |
FieldSelector.Path
Represents a field that should be excluded from or renamed in MongoDB documents.
|
private static class |
FieldSelector.RemovePath |
private static class |
FieldSelector.RenamePath |
| Modifier and Type | Field and Description |
|---|---|
private static Pattern |
COLON |
private static Pattern |
DOT |
private List<FieldSelector.Path> |
paths
The configured exclusion/renaming patterns.
|
| Modifier | Constructor and Description |
|---|---|
private |
FieldSelector(List<FieldSelector.Path> paths) |
| Modifier and Type | Method and Description |
|---|---|
static FieldSelector.FieldSelectorBuilder |
builder()
Returns a new
builder for a field selector. |
FieldSelector.FieldFilter |
fieldFilterFor(CollectionId id)
Returns the field filter for the given collection identifier.
|
private static final Pattern DOT
private static final Pattern COLON
private final List<FieldSelector.Path> paths
private FieldSelector(List<FieldSelector.Path> paths)
public static FieldSelector.FieldSelectorBuilder builder()
builder for a field selector.nullpublic FieldSelector.FieldFilter fieldFilterFor(CollectionId id)
Note that the field filter is completely independent of the collection selection predicate, so it is expected that this filter be used only after the collection selection predicate determined the collection containing documents with the field(s) is to be used.
id - the collection identifier, never nullnullCopyright © 2019 JBoss by Red Hat. All rights reserved.