jeudi 2 avril 2020

Is it a good practise to have a java class with just having one static variable?

I need to store some value in a variable which can be write from a one class and read from a another class so basically I need to hide the writing class to reading class ,So will it be a good option to have that variable in a separate class as a static variable .This project is regarding OSGI framework.

Is there any design pattern to solve this problem or will this okay?

Aucun commentaire:

Enregistrer un commentaire