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

Create a Database class #35

Open
DelaMarc opened this issue Apr 22, 2020 · 0 comments
Open

Create a Database class #35

DelaMarc opened this issue Apr 22, 2020 · 0 comments

Comments

@DelaMarc
Copy link
Contributor

I recommend creating a Database class (that would also be a singleton). It would be used to handle all database manipulations and have methods that would encapsulate the Select, Update and Delete operations of a database and return the desired result.
This class would also catch the exceptions relative to database malfunction.
With such a class, the database connexions would be handled more smoothly and if would avoid to manually put a try/catch at every SQL request in the server code.

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

1 participant