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

LCOM is not applicable to interfaces #57

Closed
eviweb opened this issue Nov 20, 2014 · 4 comments
Closed

LCOM is not applicable to interfaces #57

eviweb opened this issue Nov 20, 2014 · 4 comments

Comments

@eviweb
Copy link

eviweb commented Nov 20, 2014

As interfaces do not contain any logic and consequently attribute accesses, include them in LCOM calculation is not relevant.
Currently the overall LCOM result is distorted, and does not reflect the reality.
Maybe interfaces should be excluded from LCOM calculation or at least should not influence the result.

Eric

@Halleck45
Copy link
Collaborator

Yes, you're right. And I think that I also should remove getters and setters from calculation. I'll fix it.

@eviweb
Copy link
Author

eviweb commented Nov 20, 2014

Thanks, but I'm not pretty sure removing getters and setters is a good idea.
They are functions and so can do much more than what they are simply supposed to.
Furthermore any function can play the role of a property accessor.
IMHO, it seems to me a little bit risky to go in that way...

Eric

@Halleck45
Copy link
Collaborator

That's big question :)

According to me, LCOM is useful because it reflects responsabilities of class. Maybe we need a new metrics, LCOM5 = LCOM4 without getters and setters...

@eviweb
Copy link
Author

eviweb commented Nov 20, 2014

good idea ;)

Thanks

Eric

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

No branches or pull requests

2 participants