This is probably a stupid question, but I can't seem to do it. I want to set up some enums in one class like this:
public enum Direction { north, east, south, west };
Then have that enum type accessible to all classes so that some other class could for instance have:
Direction dir = north;
and be able to pass the enum type between classes:
public void changeDirection(Direction direction) {
dir = direction;
}
I thought that setting the enum to public would make this automatically possible, but it doesn't seem to be visible outside of the class I declared the enum in.