• The DefaultDAO class stores an instance of itself (as a Singleton) in the static variable instance, allowing access to that instance through the getInstance() method.

    DefaultDAO静态变量instance 中存储了它自己一个实例(存储Singleton),并允许通过getInstance()方法访问实例。

    youdao

  • This line of code creates a Singleton object and initializes the variable instance to refer to this object.

    此行代码创建了一个Singleton对象初始变量instance引用对象。

    youdao

  • The problem with this line of code is that the variable instance can become non-null before the body of the Singleton constructor executes.

    代码问题:在Singleton构造函数执行之前变量instance可能成为非null

    youdao

  • By simply having a member variable following the xyzService convention, Grails knows to inject the xyzService singleton.

    只要拥有遵循xyzservice约定成员变量Grails就知道需要注入xyzService单体。

    youdao

  • Since it is thread safe by design, you might cache it in a public static final variable, or wrap it in a singleton pattern after creation for later access.

    因为根据设计线程安全的,创建之后可以把它存在一个公共静态最终变量中,或者包装实例模式以供以后访问

    youdao

  • To facilitate this, the plug-in class implements the singleton pattern: It stores a reference to itself in a private class variable.

    为了使一点更方便,插件实现模式(singletonpattern):私有类变量中存储一个自身引用

    youdao

  • To facilitate this, the plug-in class implements the singleton pattern: It stores a reference to itself in a private class variable.

    为了使一点更方便,插件实现模式(singletonpattern):私有类变量中存储一个自身引用

    youdao

$firstVoiceSent
- 来自原声例句
小调查
请问您想要如何调整此模块?

感谢您的反馈,我们会尽快进行适当修改!
进来说说原因吧 确定
小调查
请问您想要如何调整此模块?

感谢您的反馈,我们会尽快进行适当修改!
进来说说原因吧 确定