3 import java.io.Serializable;
4 import java.util.Arrays;
6 public class Account implements Serializable {
11 private static final long serialVersionUID = 1L;
13 private byte[] username;
14 private byte[] password;
18 private boolean admin = false;
20 public Account(byte[] usr) {
24 public Account(Owner own) {
27 public Account(String usr, String pass, boolean isAdmin) {
31 public Account(String usr, String pass, Owner ow) {
35 public byte[] getUsername() {
39 public byte[] getPassword() {
43 public Owner getOwner() {
47 public boolean getAdmin() {
51 public void setAdmin(boolean admin) {
55 public byte[] getSalt() {
59 public void setSalt(byte[] salt) {
64 public boolean equals(Object obj) {
69 if (getClass() != obj.getClass())
71 Account other = (Account) obj;
72 if (!Arrays.equals(username, other.username))