Add project files.

This commit is contained in:
Sergio Matias Urquin
2025-04-29 18:42:29 -06:00
parent 9c1958d351
commit 83fc1878c4
67 changed files with 4586 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
namespace Core.Blueprint.Mongo
{
/// <summary>
/// The <see cref="CollectionAttributeName"/> attribute is used to specify the name of a MongoDB collection
/// that a class should be mapped to. This attribute can be applied to classes that represent MongoDB entities.
/// </summary>
[AttributeUsage(AttributeTargets.Class)] // This attribute can only be applied to classes.
public class CollectionAttributeName : Attribute
{
/// <summary>
/// Gets or sets the name of the MongoDB collection that the class is mapped to.
/// </summary>
public string Name { get; set; }
/// <summary>
/// Initializes a new instance of the <see cref="CollectionAttributeName"/> class with the specified collection name.
/// </summary>
/// <param name="name">The name of the MongoDB collection that the class should be mapped to.</param>
public CollectionAttributeName(string name)
{
Name = name ?? throw new ArgumentNullException(nameof(name), "Collection name cannot be null.");
}
}
}