public class ProjectionsKt
@NotNull
public static <T> java.lang.String getProjection(@NotNull
kotlin.reflect.KProperty<? extends T> $this$projection)
The projection of the property.
@NotNull
public static java.lang.String getProjection(@NotNull
java.lang.String $this$projection)
The projection of the property.
@NotNull
public static <T> org.bson.conversions.Bson from(@NotNull
kotlin.reflect.KProperty<? extends T> $this$from,
T expression)
Creates a projection of a property whose value is computed from the given expression.
expression - the expression@NotNull
public static org.bson.conversions.Bson from(@NotNull
org.litote.kmongo.MongoOperator $this$from,
@NotNull
java.lang.Object expression)
Builds Bson for the MongoOperator and the specified expression.
@NotNull
public static org.bson.conversions.Bson from(@NotNull
java.lang.String $this$from,
@NotNull
java.lang.Object expression)
Builds Bson from this String format and the specified expression.
@NotNull
public static org.bson.conversions.Bson include(@NotNull
kotlin.reflect.KProperty... properties)
Creates a projection that includes all of the given properties.
properties - the field names@NotNull
public static org.bson.conversions.Bson include(@NotNull
java.lang.Iterable<? extends kotlin.reflect.KProperty<?>> properties)
Creates a projection that includes all of the given properties.
properties - the field names@NotNull
public static org.bson.conversions.Bson exclude(@NotNull
kotlin.reflect.KProperty... properties)
Creates a projection that excludes all of the given properties.
properties - the field names@NotNull
public static org.bson.conversions.Bson exclude(@NotNull
java.lang.Iterable<? extends kotlin.reflect.KProperty<?>> properties)
Creates a projection that excludes all of the given properties.
properties - the field names@NotNull public static org.bson.conversions.Bson excludeId()
Creates a projection that excludes the _id field. This suppresses the automatic inclusion of _id that is the default, even when other fields are explicitly included.
@NotNull
public static <T> org.bson.conversions.Bson elemMatchProj(@NotNull
kotlin.reflect.KProperty<? extends T> $this$elemMatchProj)
Creates a projection that includes for the given property only the first element of an array that matches the query filter. This is referred to as the positional $ operator.
@NotNull
public static <T> org.bson.conversions.Bson elemMatchProj(@NotNull
kotlin.reflect.KProperty<? extends T> $this$elemMatchProj,
@NotNull
org.bson.conversions.Bson filter)
Creates a projection that includes for the given property only the first element of the array value of that field that matches the given query filter.
filter - the filter to apply@NotNull
public static <T> org.bson.conversions.Bson metaTextScore(@NotNull
kotlin.reflect.KProperty<? extends T> $this$metaTextScore)
Creates a projection to the given property of the textScore, for use with text queries.
@NotNull
public static <T> org.bson.conversions.Bson slice(@NotNull
kotlin.reflect.KProperty<? extends T> $this$slice,
int limit)
Creates a projection to the given property of a slice of the array value of that field.
limit - the number of elements to project.@NotNull
public static <T> org.bson.conversions.Bson slice(@NotNull
kotlin.reflect.KProperty<? extends T> $this$slice,
int skip,
int limit)
Creates a projection to the given property of a slice of the array value of that field.
skip - the number of elements to skip before applying the limitlimit - the number of elements to project@NotNull
public static org.bson.conversions.Bson fields(@NotNull
org.bson.conversions.Bson... projections)
Creates a projection that combines the list of projections into a single one. If there are duplicate keys, the last one takes precedence.
projections - the list of projections to combine@NotNull
public static org.bson.conversions.Bson fields(@NotNull
java.util.List<? extends org.bson.conversions.Bson> projections)
Creates a projection that combines the list of projections into a single one. If there are duplicate keys, the last one takes precedence.
projections - the list of projections to combine