I'm not too quite sure about what i should do about a grouped set of classes.
My situation: I have 11 classes that relate only to the class Character.cs
, but all of those classes (including Character.cs
and CharacterManager.cs
) are within the namespace Models.Characters
.
Which is the more "proper" or preferred way of naming the classes:
(examples):
CharacterDetails.cs
CharacterSprites
CharacterAppearance
CharacterClientRights
CharacterServerRights
or:
Details.cs
Sprites
Appearance
ClientRights
ServerRights
(They're all noticed in Models.Characters
(so eg. Models.Characters.CharacterDetails
, Models.Characters.Appearance
)
Thanks in advance.
Personally for me it"depends". Usually I would prefix everything with the word Character
to keep things consistant, however if you have everything already under the Character
namespace the Character prefix could seem redundant.
I could easily see going with the shorter convention of Models.Character.[X]
if there never will be another class called Details
, if there for instance could be UserDetails
then Details
and UserDetails
could be confusing when looking back at the code weeks or months from now and I would personally prefer then the CharacterDetails
option.
In the end it is your personal preference, what more accurately describes your domain, Details
or CharacterDetails
?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With