Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use searchable names (part 2) #73

Open
boop5 opened this issue Dec 2, 2019 · 2 comments
Open

Use searchable names (part 2) #73

boop5 opened this issue Dec 2, 2019 · 2 comments

Comments

@boop5
Copy link

boop5 commented Dec 2, 2019

I think you broke a rule within the example of another.


In Don't add unneeded context you say that this is bad

public class Car
{
    public string CarMake { get; set; }
    public string CarModel { get; set; }
    public string CarColor { get; set; }

    //...
}

But then you do it in Use searchable names (part 2)

public enum PersonAccess : int
{
    ACCESS_READ = 1,
    ACCESS_CREATE = 2,
    ACCESS_UPDATE = 4,
    ACCESS_DELETE = 8
}

So it actually should look like this IMO

public enum PersonAccess : int
{
    Read = 1,
    Create = 2,
    Update = 4,
    Delete = 8
}
@dmitryvhf
Copy link

But then you do it in Use searchable names (part 2)

This made only for fix PersonAccess = 4 to searchable names.
But you are right. Your example better.

@tiagossa1
Copy link

@boop5 agreed. Your example looks better than the one provided on the repo, atlhough I prefer to write constants/enums/const names in Capslock. I find it easier to read.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants