[CSHARP-206] Rename ObjectId.GenerateNewId to ObjectId.NewId() to meet Guid.NewGuid() Created: 19/Apr/11  Updated: 02/Apr/15  Resolved: 08/Jul/11

Status: Closed
Project: C# Driver
Component/s: None
Affects Version/s: 1.0
Fix Version/s: 1.1

Type: Improvement Priority: Major - P3
Reporter: Steve Wagner Assignee: Robert Stam
Resolution: Done Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Its also shorter and should result in better readability.



 Comments   
Comment by Robert Stam [ 08/Jul/11 ]

Keeping the current name.

Comment by Steve Wagner [ 19/Apr/11 ]

Yes but GenerateNewId is a little bit long. Maybe then ObjectId.Generate() is better.

Comment by Robert Stam [ 19/Apr/11 ]

If you look at the .NET documentation almost every member named NewXyz is a property, not a method. The .NET naming conventions recommend that method names be verbs, not nouns (nouns are properties). So Guid.NewGuid is actually not following the standard naming conventions.

Will leave this ticket open to see what other comments come in.

Generated at Wed Feb 07 21:36:07 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.