01: /*
02: * enhydraManager
03: *
04: * Enhydra super-servlet
05: *
06: */
07:
08: package org.enhydra.snapperAdmin;
09:
10: import com.lutris.appserver.server.user.User;
11:
12: /**
13: * This class provides a User object. There should only be one administrator
14: * logged in at a time, but if more than one does they will share the same
15: * User object.
16: */
17: public class SnapperUser implements User, java.io.Serializable {
18:
19: /**
20: * Use this User object when someone logs in.
21: */
22: // protected static SnapperUser sharedUser = new SnapperUser("Administrator");
23:
24: /**
25: * The user's name.
26: */
27: private String username;
28:
29: /**
30: * Only create one instance.
31: */
32: public SnapperUser(String username) {
33: this .username = username;
34: }
35:
36: /**
37: * Returns the username of the user.
38: *
39: * @return The user's name.
40: */
41: public String getName() {
42: return username;
43: }
44:
45: }
|