Class NpgsqlRangeDbFunctionsExtensions
- Namespace
- Microsoft.EntityFrameworkCore
- Assembly
- Npgsql.EntityFrameworkCore.PostgreSQL.dll
Provides extension methods for NpgsqlRange<T> supporting PostgreSQL translation.
public static class NpgsqlRangeDbFunctionsExtensions
- Inheritance
-
NpgsqlRangeDbFunctionsExtensions
- Inherited Members
Methods
ContainedBy<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range is contained by a specified range.
public static bool ContainedBy<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The specified range to locate in the range.
b
NpgsqlRange<T>The range in which to locate the specified range.
Returns
- bool
true if the range contains the specified range; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
ContainedBy<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
Contains<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range contains a specified range.
public static bool Contains<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The range in which to locate the specified range.
b
NpgsqlRange<T>The specified range to locate in the range.
Returns
- bool
true if the range contains the specified range; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
Contains<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
Contains<T>(NpgsqlRange<T>, T)
Determines whether a range contains a specified value.
public static bool Contains<T>(this NpgsqlRange<T> range, T value)
Parameters
range
NpgsqlRange<T>The range in which to locate the value.
value
TThe value to locate in the range.
Returns
- bool
true if the range contains the specified value; otherwise,false .
Type Parameters
T
The type of the elements of
range
.
Exceptions
- NotSupportedException
Contains<T>(NpgsqlRange<T>, T) is only intended for use via SQL translation as part of an EF Core LINQ query.
DoesNotExtendLeftOf<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range does not extend to the left of another range.
public static bool DoesNotExtendLeftOf<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- bool
true if the first range does not extend to the left of the second; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
DoesNotExtendLeftOf<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
DoesNotExtendRightOf<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range does not extend to the right of another range.
public static bool DoesNotExtendRightOf<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- bool
true if the first range does not extend to the right of the second; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
DoesNotExtendRightOf<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
Except<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Returns the set difference, which means the elements of one range that do not appear in a second range.
public static NpgsqlRange<T> Except<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- NpgsqlRange<T>
The elements that appear in the first range, but not the second range.
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
Except<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
Intersect<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Returns the set intersection, which means elements that appear in each of two ranges.
public static NpgsqlRange<T> Intersect<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- NpgsqlRange<T>
A range containing the elements that appear in both ranges.
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
Intersect<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
IsAdjacentTo<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range is adjacent to another range.
public static bool IsAdjacentTo<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- bool
true if the ranges are adjacent; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
IsAdjacentTo<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
IsStrictlyLeftOf<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range is strictly to the left of another range.
public static bool IsStrictlyLeftOf<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- bool
true if the first range is strictly to the left of the second; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
IsStrictlyLeftOf<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
IsStrictlyRightOf<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range is strictly to the right of another range.
public static bool IsStrictlyRightOf<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- bool
true if the first range is strictly to the right of the second; otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
IsStrictlyRightOf<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
Merge<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Returns the smallest range which includes both of the given ranges.
public static NpgsqlRange<T> Merge<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- NpgsqlRange<T>
The smallest range which includes both of the given ranges.
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
Merge<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
Overlaps<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Determines whether a range overlaps another range.
public static bool Overlaps<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- bool
true if the ranges overlap (share points in common); otherwise,false .
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
Overlaps<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.
RangeAgg<T>(IEnumerable<NpgsqlRange<T>>)
Computes the union of the non-null input ranges. Corresponds to the PostgreSQL range_agg
aggregate function.
public static NpgsqlRange<T>[] RangeAgg<T>(this IEnumerable<NpgsqlRange<T>> input)
Parameters
input
IEnumerable<NpgsqlRange<T>>The ranges to be aggregated via union into a multirange.
Returns
- NpgsqlRange<T>[]
Type Parameters
T
Exceptions
- NotSupportedException
RangeAgg<T>(IEnumerable<NpgsqlRange<T>>) is only intended for use via SQL translation as part of an EF Core LINQ query.
- See Also
RangeIntersectAgg<T>(IEnumerable<NpgsqlRange<T>[]>)
Computes the intersection of the non-null input multiranges.
Corresponds to the PostgreSQL range_intersect_agg
aggregate function.
public static NpgsqlRange<T>[] RangeIntersectAgg<T>(this IEnumerable<NpgsqlRange<T>[]> input)
Parameters
input
IEnumerable<NpgsqlRange<T>[]>The multiranges on which to perform the intersection operation.
Returns
- NpgsqlRange<T>[]
Type Parameters
T
Exceptions
- NotSupportedException
RangeIntersectAgg<T>(IEnumerable<NpgsqlRange<T>[]>) is only intended for use via SQL translation as part of an EF Core LINQ query.
- See Also
RangeIntersectAgg<T>(IEnumerable<NpgsqlRange<T>>)
Computes the intersection of the non-null input ranges. Corresponds to the PostgreSQL range_intersect_agg
aggregate function.
public static NpgsqlRange<T> RangeIntersectAgg<T>(this IEnumerable<NpgsqlRange<T>> input)
Parameters
input
IEnumerable<NpgsqlRange<T>>The ranges on which to perform the intersection operation.
Returns
- NpgsqlRange<T>
Type Parameters
T
Exceptions
- NotSupportedException
RangeIntersectAgg<T>(IEnumerable<NpgsqlRange<T>>) is only intended for use via SQL translation as part of an EF Core LINQ query.
- See Also
Union<T>(NpgsqlRange<T>, NpgsqlRange<T>)
Returns the set union, which means unique elements that appear in either of two ranges.
public static NpgsqlRange<T> Union<T>(this NpgsqlRange<T> a, NpgsqlRange<T> b)
Parameters
a
NpgsqlRange<T>The first range.
b
NpgsqlRange<T>The second range.
Returns
- NpgsqlRange<T>
A range containing the unique elements that appear in either range.
Type Parameters
T
The type of the elements of
a
.
Exceptions
- NotSupportedException
Union<T>(NpgsqlRange<T>, NpgsqlRange<T>) is only intended for use via SQL translation as part of an EF Core LINQ query.