Skip to content

Commit

Permalink
singleton class for holding current user
Browse files Browse the repository at this point in the history
  • Loading branch information
dep11007 committed May 1, 2015
1 parent 03e4fec commit aa72125
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
Binary file modified bin/thermostat/ThermostatDevice.class
Binary file not shown.
34 changes: 34 additions & 0 deletions src/InputOutput/CurrentUser.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
package InputOutput;

/**
* Created by David on 5/1/15.
*/
public class CurrentUser {

private static CurrentUser instance = null;

private String email;

public static CurrentUser getInstance() {
if (instance == null){
try {
instance = new CurrentUser();
} catch (Exception e) {
e.printStackTrace();
}
}
return instance;
}

public CurrentUser(){
}

public String getEmail(){
return this.email;
}

public void setEmail(String email){
this.email = email;
}

}

0 comments on commit aa72125

Please sign in to comment.