Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to name an interface which shows the existence of a property?

I want to create an interface which should tell its client that the type has a realm property, but I'm struggling on how to name it.

Something like HasRealm or HasRealmProperty? Are the any conventions on how to name such an interface?

Edit

By property I mean attribute.

Edit 2

Further, the interface has to provide a setRealm(String realm) method. So, it's more like SettableRealm (sry, I'm not good at naming).

like image 265
helpermethod Avatar asked Oct 30 '25 14:10

helpermethod


2 Answers

I've encountered similar-goal interfaces having the suffix Aware. So, in your case it will be RealmAware.

like image 120
Alexander Pavlov Avatar answered Nov 02 '25 02:11

Alexander Pavlov


If you mean any 'official' convention I would say: no there isn't any convention. And as long as you keep consistent in your project, it doesn't matter. Personally I would go by "HasRealm".

like image 35
Joachim Rohde Avatar answered Nov 02 '25 04:11

Joachim Rohde



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!