单词 | singleton pattern | ||||||||||||
释义 | singleton pattern
更多释义 收起释义 例句释义: 单例模式,单件模式,设计模式之单件模式 1. The Singleton pattern applies to situations in which there needs to be a single instance of a class. 单例模式支持那些需要只保存一个单独的实例的类。 blog.sina.com.cn 2. Most caches are implemented using the Singleton pattern involving a static reference to a top level Cache class as shown in this example. 使用Singleton模式实现的大多数缓存都涉及本例所示的对顶级Cache类的静态引用。 www.ibm.com 3. As its name suggests, the Singleton Pattern is typically used when you want only one instance of a particular class. 如其名称所暗示的,当您想要特别类的仅仅一个实例时,才使用Singleton模式。 www.ibm.com 4. The singleton pattern can be used to delay the initialization of an object as long as possible. 单元素模式可以用来尽可能久地延迟对象的初始化。 www.cnblogs.com 5. However, the project had two closely related scenarios where the singleton pattern proved useful: for logging and exception handling. 不过本项目中有两个紧密相关的场景可以证明独立模式是有用的:可以用于日志记录和异常处理。 www.ibm.com 6. To facilitate this, the plug-in class implements the singleton pattern: It stores a reference to itself in a private class variable. 为了使这一点更方便,插件类实现单模式(singletonpattern):它在私有类变量中存储一个自身的引用。 www.ibm.com 7. To create an instance of the Factory Method Pattern, perform the same steps as for the Singleton Pattern. 要创建Factory方法模式的实例,执行同Singleton模式相同的步骤。 www.ibm.com 8. Create a private attribute for the Singleton Pattern called _instance. 为Singleton模式创建私有属性,称为_instance。 www.ibm.com 9. Drag and drop the Singleton Pattern instance from the Pattern Explorer into the UML Class Diagram view. 将Singleton模式实例从模式浏览器中拖拽到UML类图视图中。 www.ibm.com 10. Doing so creates an instance of the Singleton Pattern in the Model Explorer. 执行此操作将会在模型浏览器中生成一个Singleton模式的实例。 www.ibm.com 1. The Singleton pattern is shown in Figure 5. Singleton模式如图5所示。 www.ibm.com 2. The singleton pattern is baked directly into Scala and is used anywhere you would use static methods or variables in the Java language. 单例模式被直接内置在Scala中,可以替代Java语言中的静态方法或变量。 www.ibm.com 3. If we follow a straight singleton pattern for PoIdGenerator, this can be problematic. 如果我们使用PoIdGenerator的直接单一模式,可能会出现问题。 www.ibm.com 4. Using the UML-Java transformation, generate the code for the Singleton Pattern (see Listing 1). 利用UML到Java的转换,为Singleton模式生成代码(参见清单1)。 www.ibm.com 5. This is a standard PHP singleton pattern. 这是一个标准的PHP单元素模式。 www.ibm.com 6. Using C# 2. 0 Generics to achieve a reusable Singleton pattern 使用C#2.0泛型来完成单例模式的重用 www.cnblogs.com |
||||||||||||
随便看 |
|
英汉双解词典包含2704715条英汉词条,基本涵盖了全部常用单词的翻译及用法,是英语学习的有利工具。