Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oliviagallucci/568d5006c9c4a6dcba106f7991262bb6 to your computer and use it in GitHub Desktop.
Save oliviagallucci/568d5006c9c4a6dcba106f7991262bb6 to your computer and use it in GitHub Desktop.
/**
* Creates an instance of LoginDatabaseDAO
*
* Used for specificying the functionality of overriden functions
* checkCredentials() and register() that gets dependency injected
* into the RESTController element
*/
public LoginDatabaseDAO(){
try {
// the URL connects to the database as user=estore and password=password
this.connect = DriverManager
.getConnection("jdbc:mysql://smt5541pi.student.rit.edu:3306/book?"
+ "user=estore&password=password");
} catch (SQLException e) {
e.printStackTrace();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment