自定义类型使用泛型

package com.bjpowernode.t02generic;

/*
* 泛型模板
*/
public class TestGeneric04 {

public static void main(String[] args) {
//自定义类型使用泛型
MyList<Integer> ml = new MyList<>();
ml.setE(123);
ml.getE();
MyList.m1("hello");
}

}

posted @ 2018-08-30 17:44  Monica_维维  阅读(173)  评论(0编辑  收藏  举报