Declares a new class initializer inside a class declaration.
在类声明中声明新的类初始值设定项。
The following example demonstrates using the base class initializer.
下列范例示范使用基底类别初始设定式。
If a _metaclass_ hook is defined after the class initializer, it silently overrides it.
如果_ metaclass _钩子在类初始化器之后定义,它会静静地覆盖类初始化器。
The metaclass will create the class (as a new style one) and will pass it to the class initializer procedure.
元类将创建此类(作为一个新式类)并将其传递给类初始化器过程。
The other motivation is that even for Python wizards it is very inconvenient to rewrite the code managing the _metaclass_ hook every time one writes a new class initializer.
另一个动机是,即使对于python奇才来说,每次编写新的类初始化器时都得重写管理_ metaclass _钩子的代码也是很不方便的。
The class initializer does not disturb the metaclass of C, which is the one inherited by base B, and the inherited metaclass does not disturb the class initializer, which does its job just fine.
类初始化器并没有干扰到C的元类,它继承了基类B,并且继承的元类不但不会影响到类初始化器,而且会很好地运行。
To instantiate the object within the shared memory, define an additional class, Initializer.
要对共享内存中的对象进行实例化,请定义另外一个类Initializer。
The static initializer in Listing 2 shows the registration process for a Customer class that contains two properties: name and salary.
清单2中的静态初始化器显示了Customer类的注册过程,这个类包含两个属性:name和salary。
The com.dW.dWRFD1Handler class is basic, consisting mostly of an initializer, getters, and setters, and it should not require much further discussion.
dWRFD1Handler类很简单,主要由一个初始化程序、getter和setter 组成,对它应该没必要再作讨论。
The static initializer runs first, as the class is loaded, followed by the main method (which is also static).
加载类之后,静态初始化器首先运行,紧接着运行的是main方法(也是静态的)。
The wordform_handler class has an initializer and keeps track of the parameter passed in to determine whether to apply XSLT to XML results.
wordform_handler类有一个初始化器,并记录传递的参数,决定是否对XML结果应用XSLT。
This information resides in a BeanInfo class, which is typically provided by your bean when the bean's class is loaded via a static initializer.
这条信息位于beaninfo类中,该类通常在bean的类通过静态初始化器装入时,由bean提供。
The first set of enclosing braces delineates the construction of an anonymous inner class, and the second set delineates the instance initializer for the anonymous inner class.
第一组闭合括弧划定一个匿名内部类的构造,第二组划定匿名内部类的实例初始化语句块。
We use the EmbeddedDriver for our driver class in the static initializer of the class.
我们将在类的静态初始化器中把 EmbeddedDriver 用于驱动程序类。
A permissions class with a static initializer provides a single location for declaring and configuring available application permissions.
带有静态初始化器的permissions类为声明和配置可用的应用程序权限提供单一位置。
In a static initializer block, which executes when the class is loaded.
在一个静态初始化块中,在加载类时执行。
A constructor initializer list specifies initial values for one or more data members of the class.
构造函数的初始化列表为类的一个或多个数据成员指定初值。
This is the designated initializer for this class.
这个是指定这个类初始化。
Class members that are not initialized in the initializer list are implicitly initialized by using their default constructor.
没有在初始化列表中初始化的类成员,使用它们的默认构造函数隐式初始化。
It cannot be used in the initializer list for a base class.
它无法在基底类别的初始设定式清单中使用。
When overridden in a derived class, returns an array of initializer objects corresponding to an input array of method definitions.
在派生类中重写时,返回与方法定义的输入数组对应的初始值设定项对象的数组。
When overridden in a derived class, returns an initializer for the specified method.
在衍生类别中覆写时,会传回指定之方法的初始设定式。
When you use an object initializer to create an instance of a named type, the default constructor for the class is called, followed by initialization of designated members in the order you specify.
当您使用物件初始设定式来建立具名型别的执行个体时,会呼叫类别的预设建构函式,接著按照您指定的顺序初始化指定的成员。
When you use an object initializer to create an instance of a named type, the default constructor for the class is called, followed by initialization of designated members in the order you specify.
当您使用物件初始设定式来建立具名型别的执行个体时,会呼叫类别的预设建构函式,接著按照您指定的顺序初始化指定的成员。
应用推荐