public HashSet<String> Red;
public HashSet<String> Blue;
public HashSet<String> Colors;
public Data(HashSet<String> red, HashSet<String> blue, HashSet<String> colors) {
Red = red;
Blue = blue;
Colors = colors;
}
我尝试在此对象中存储 3 个 Set / HashSet。这种方式是否正确,我可以像普通对象一样访问 Set/HashSet 对象吗?
public Set<String> Red = new HashSet<String>();