我正在使用ListNode作为内部类创建一个类,Doubly Linked List.
public class DoublyLinkedList<Integer> {
/** Return a representation of this list: its values, with adjacent
* ones separated by ", ", "[" at the beginning, and "]" at the end. <br>
*
* E.g. for the list containing 6 3 8 in that order, return "[6, 3, 8]". */
public String toString() {
String s;
ListNode i = new ListNode(null, null, *new Integer(0)*);
Run Code Online (Sandbox Code Playgroud)
为什么我得到错误,无法实例化类型Integer?