[#26] All: Remove V2 from naming

Rename project, namespaces and class names

Signed-off-by: Pavel Gross <p.gross@yadro.com>
This commit is contained in:
Pavel Gross 2024-11-18 11:11:17 +03:00
parent c406df1a78
commit 766f61a5f7
219 changed files with 219 additions and 974 deletions

View file

@ -0,0 +1,33 @@
using System;
using FrostFS.Refs;
using Google.Protobuf;
namespace FrostFS.SDK.Client.Mappers.GRPC;
public static class ObjectIdMapper
{
public static ObjectID ToMessage(this FrostFsObjectId objectId)
{
if (objectId is null)
{
throw new ArgumentNullException(nameof(objectId));
}
return new ObjectID
{
Value = ByteString.CopyFrom(objectId.ToHash())
};
}
public static FrostFsObjectId ToModel(this ObjectID objectId)
{
if (objectId is null)
{
throw new ArgumentNullException(nameof(objectId));
}
return FrostFsObjectId.FromHash(objectId.Value.ToByteArray());
}
}