检索规则说明:AND代表“并且”;OR代表“或者”;NOT代表“不包含”;(注意必须大写,运算符两边需空一格)
检 索 范 例 :范例一: (K=图书馆学 OR K=情报学) AND A=范并思 范例二:J=计算机应用与软件 AND (U=C++ OR U=Basic) NOT M=Visual
作 者:肖永刚[1]
出 处:《兰州工业高等专科学校学报》2012年第6期20-23,共4页Journal of Lanzhou Higher Polytechnical College
摘 要:介绍了应用装饰模式自动生成CSS的方法.原始的设计是基于继承的,子类功能的增加是通过覆盖或扩展父类方法实现的.优化的设计应用了装饰模式,获得了良好的可扩展性和可维护性.将CSS细分成不同的部分,每个部分作为一个装饰类.可以根据需要灵活地使用这些装饰类生成不同风格的CSS.通过对比这两种设计方式,最后列出了利用装饰模式的优缺点.This paper introduces the application of Decorator Pattern in the field of creating CSS automatically. The original design is based on inheritance and the additional functionality of subclasses is implemented by over- riding or extending methods in the superclass. The optimized design that applies Decorator Pattern accommodates the future extension and maintenance. It divides a CSS file into several parts, each of which develops into a dec- orator. These decorators can be flexibly used to create CSS of different style. The processes of both designs are explained in detail. By contrasting both designs, the advantages and disadvantages of the pattern are listed.
分 类 号:TP31[自动化与计算机技术—计算机软件与理论]
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在链接到云南高校图书馆文献保障联盟下载...
云南高校图书馆联盟文献共享服务平台 版权所有©
您的IP:216.73.216.30