I have 2 classes which I am making in blueJ- one called User and the other UserGroup. My user class looks like this:
public class User{
public enum UserType{
ADMIN, EDITOR, USER;
}
public String id;
public UserType userPermissions;
public String actualName;
public User(String username, UserType userType, String name){
id = username;
userPermissions = userType;
actualName= name;
}
public String getUsername(){
return id;
}
public UserType getUserType(){
return userPermissions;
}
public String getName(){
return actualName;
}
public void setUserType(UserType input){
userPermissions = input;
}
}
And my UserGroup class like this so far:
import java.util.*;
public class UserGroup{
private static ArrayList<User> UserGroup= new ArrayList<User>();
public static void add(String username, UserType userType, String name){
UserGroup.add(new User(username, userType,name));
}
}
My problem is when I try to compile UserGroup it says "cannot find symbol- class UserType". I am trying to create an arraylist in UserGroup of Users created in the User class. Where am I going wrong?