用模板方法加入和重写行为。
模板方法模式和抽象类的不同在与处理工作流程。
This differs from the Template Method pattern in that the abstract superclass doesn't handle workflow.
创建实例指定的模板方法,用在一次性的设计中。
Create instance-specific template methods in one-off situations.
模板方法模式的这种用法提供了关注点的好的分离。
Such USES of the Template Method pattern offer good separation of concerns.
采用网格模板方法产生具有分形结构的岩体裂隙网。
The fractal network model of fractured rock is generated as a lattice structure.
我说暴露文摘块模板方法模式是更好的在许多情况下。
I am saying exposing abstract blocks in template method pattern is better in many scenarios.
提出一种主次模板方法,构建面向童话故事的概念关系。
This paper proposes a primary and secondary template method to construct the conceptual relation of fairy tale.
最后利用此法得到的唇部信息与变形模板方法相结合建立唇部模型。
Finally, The lip model is created by deformable templates and lip information got form this approach.
应用创造性模板方法对模板信息进行处理,从而产生新的产品方案。
Then creativity templates are used to process information and the new products…
策略设计模式比模板方法模式花费了更多的工作去实现,但是它也更灵活。
The Strategy design pattern takes a little more work to implement than the Template Method pattern, but it is more flexible.
模板方法可以由实现者提供,但必须注意的一点是超类有可能已经实现了其模板方法。
Template methods can be provided by the implementer, who must not forget that the superclass can potentially have implemented its template methods.
模板方法模式的另一个选择是策略模式,它抽取了多变的行为到一个接口中。
An alternative to the Template Method is the Strategy design pattern, which factors the variant behavior into an interface.
这稍微的更复杂去实现比用模板方法模式在类继承的版本中,但是也更灵活。
This is slightly more complex to implement than the version using concrete inheritance with the Template Method pattern, but is more flexible.
由于通常定义接口比定义类更好,模板方法模式通常被用于实现接口的策略。
As it's usually better to define types in interfaces rather than classes, the Template Method pattern is often used as a strategy to implement an interface.
由于模板方法模式是受保护的,而不是公共方法,调用者被分离从类实现的细节中。
As the template methods are protected, rather than public, callers are spared the details of the class's implementation.
在此介绍采用GOF的模板方法模式及采用回溯算法的模板方法模式的设计与实现。
Template method pattern of GOF and the realization of template method pattern in back tracing algorithm are introduced.
模板方法模式使得子类可以不改变一个算法的结构即可重定义该算法的某些特定步骤。
Template Method lets subclasses redefine certain steps of an algorithm without changing the algorithm's structure.
对童话故事内容进行抽取概念对的实验,结果表明,采用主次模板方法具有较高的正确率。
It extracts the concept pair of the fairy tale, experimental results show that the primary and secondary template method has high precision rate.
使用模板方法实现中介模式的桥接角色,这种做法提供了一种可以在将来添加外部通信备用类型的机制。
Using the template method for implementing the bridge role of the broker pattern provided a mechanism for adding alternative types of external communication in the future.
execute方法委托抽象的模板方法doExecute()负责继续处理原始的连接点。
The execute method delegates to an abstract template method, doExecute(), which is responsible for proceeding with the original join point.
这意味着,大部分应用程序在PIM中确定,并且业务逻辑主要在所生成的模板方法“的范围内”开发。
This means that the majority of an application is defined in the PIM, and business logic is developed largely "between the braces" of generated template methods.
与其它规则模板方法不同,所介绍的规则模板比较接近规则表达式,因而更便于与用户交互。
Distinguished from other rule template methods, our rule template is closer to regular expressions, so the interaction with user is more easily.
基于短语本位语法体系,本文提出了一个混合模板方法用于实现汉语口语对话系统语言生成器。
Based on the phrase-standard grammar system, a hybrid-template method is planned out to realize the language generator of Chinese spoken dialogue system.
模板方法使子类可以在不改变一个算法的结构的情况下,就可以重定义该算法的某些特定步骤。
Template Method lets subclasses redefine certain steps of an algorithm without changing the algorithm's structure.
总是使抽象父类实现一个接口。模板方法设计模式在框架设计中特别有价值(在这章的结尾讨论了)。
Always make the abstract parent class implement an interface. The Template Method design pattern is especially valuable in framework design (discussed towards the end of this chapter).
中介模式的“桥接”角色是使用模板方法模式实现的,它通过几种不同的基础通信技术,为远程服务调用提供支持。
The "bridge" role from the broker pattern was then implemented using the template method pattern to support remote service invocation using several different underlying communication technologies.
OASISCAM模板方法是基于XML内容处理和验证的简单方法,它允许企业创建xml格式的通用交换模型。
The OASIS CAM template approach is based on a simple approach to XML content handling and validation that allows businesses to create common interchange models for their exchanges in XML.
通过这些工具使用模板方法的另一个好处是您可以通过内容与表示方法的分离在uber和较少的技术类员工之间实现劳动力的合理分工。
An added benefit of using a template approach with such tools is that you can achieve a division of labor between the uber and less technical staff with the separation of content and presentation.
如果断言失败,那么这些方法将抛出AssertionFailedError,TestResult在结果处理装置模板方法中捕获这些异常并进行解释。
When the assertions fail, the methods throw AssertionFailedError, which TestResult catches and interprets in the result-handling fixture template method.
模板方法设计模式(gof)强调了一个普遍的问题:我们知道算法的每一步,并且知道他们执行的顺序,但是我们不知道怎么样去执行所有的这些步骤。
The Template Method design pattern (GoF) addresses a common problem: we know the steps of an algorithm and the order in which they should be performed, but don't know how to perform all of the steps.
应用推荐