正文

Java中引用另一个类里的集合,通常有以下几种方法: 1. 通过方法返回 - 在另一个类中定义一个方法,该方法返回所需集合的引用。 ```java public class ClassA { public List getMyList() { List myList = new