摘要:
工厂方法 Factory Method Define an interface for creating an object. but let subclasses decide which class to instantiate. Factory Method lets a class defe 阅读全文
摘要:
装饰器模式 Decorator Attach additional responsibilities to an object dynamically. Decorators provide a flexible alternative to subclassing for extending fu 阅读全文
摘要:
List、Set List:有序、可重复 Set:无序、不重复 互相转化 List list = [1, 2, 1]; Set set = list.toSet(); List sList = set.toList(); 遍历forEach List list = [1, 2, 1]; list.f 阅读全文