Created
September 29, 2017 15:52
-
-
Save NMZivkovic/e6f798baa77e196e3bff75c3b6576160 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using MongoDB.Bson; | |
using MongoDB.Bson.Serialization.Attributes; | |
namespace MongoDb | |
{ | |
/// <summary> | |
/// Class used in business logic to represent user. | |
/// </summary> | |
public class User | |
{ | |
[BsonId] | |
public ObjectId Id { get; set; } | |
[BsonElement("name")] | |
public string Name { get; set; } | |
[BsonElement("blog")] | |
public string Blog { get; set; } | |
[BsonElement("age")] | |
public int Age { get; set; } | |
[BsonElement("location")] | |
public string Location { get; set; } | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment