Browse Source

Rename

pull/1631/head
Ferdinando Papale 6 days ago
parent
commit
d8e20336b3
  1. 4
      src/MongoDB.Bson/ObjectModel/BsonTypeExtensions.cs
  2. 2
      src/MongoDB.Driver.Encryption/CsfleSchemaBuilder.cs
  3. 2
      src/MongoDB.Driver/Linq/Linq3Implementation/Ast/AstEnumExtensions.cs
  4. 4
      src/MongoDB.Driver/Linq/Linq3Implementation/Ast/Filters/AstTypeFilterOperation.cs

4
src/MongoDB.Bson/ObjectModel/BsonTypeExtensions.cs

@ -23,10 +23,10 @@ namespace MongoDB.Bson
public static class BsonTypeExtensions
{
/// <summary>
/// Maps a <see cref="BsonType"/> to its corresponding string representation.
/// Maps a <see cref="BsonType"/> to its corresponding server string representation.
/// </summary>
/// <param name="type">The input type to map.</param>
public static string ToStringRepresentation(this BsonType type)
public static string ToServerString(this BsonType type)
{
return type switch
{

2
src/MongoDB.Driver.Encryption/CsfleSchemaBuilder.cs

@ -281,7 +281,7 @@ namespace MongoDB.Driver.Encryption
if (bsonTypes != null)
{
var convertedBsonTypes = bsonTypes.Select(type => type.ToStringRepresentation()).ToList();
var convertedBsonTypes = bsonTypes.Select(type => type.ToServerString()).ToList();
if (convertedBsonTypes.Count == 0)
{

2
src/MongoDB.Driver/Linq/Linq3Implementation/Ast/AstEnumExtensions.cs

@ -21,7 +21,7 @@ namespace MongoDB.Driver.Linq.Linq3Implementation.Ast
{
internal static class AstEnumExtensions
{
public static string Render(this BsonType type) => type.ToStringRepresentation();
public static string Render(this BsonType type) => type.ToServerString();
public static string Render(this ByteOrder byteOrder)
{

4
src/MongoDB.Driver/Linq/Linq3Implementation/Ast/Filters/AstTypeFilterOperation.cs

@ -52,11 +52,11 @@ namespace MongoDB.Driver.Linq.Linq3Implementation.Ast.Filters
if (_types.Count == 1)
{
var type = _types[0];
return new BsonDocument("$type", type.ToStringRepresentation());
return new BsonDocument("$type", type.ToServerString());
}
else
{
return new BsonDocument("$type", new BsonArray(_types.Select(type => type.ToStringRepresentation())));
return new BsonDocument("$type", new BsonArray(_types.Select(type => type.ToServerString())));
}
}
}

Loading…
Cancel
Save