CMPUT301F18T24 / Mark-Me

This is an Android app for keeping track of medical issues.
Apache License 2.0
4 stars 4 forks source link

Elastic Search Controller: Implement singleton pattern correctly #92

Open vppatel111 opened 5 years ago

vppatel111 commented 5 years ago

Use of private access modifiers where applicable, to enforce information hiding (Referring to Elastic Search controller): The Singleton pattern usually uses a private constructor to restrict the creation of new instances by other classes. See here https://en.wikipedia.org/wiki/Singleton_pattern

ie. The setClient() method in the elasticsearch controller should be private. It's probably better to follow the singleton pattern that we saw in the lab slides.

rizwan146 commented 5 years ago

resolved in #94