Instead of defining a separate class for empty lists, it represents empty lists by putting a null pointer in both fields.
它在两个域中都放置一个空指针来表示空链表,而不是为空链表定义一个单独的类。
The quick but incorrect way to remedy the problem would be to eliminate the Leaf class and represent Leaf nodes simply by putting null Pointers in the left and right fields of a Branch.
一种快速但不正确的解决这个问题的方法是除去Leaf类并通过简单地将空指针放在Branch的left和right字段中来表示leaf节点。
Unchecked exceptions which are descendents of RuntimeException class are the ideal candidate exceptions handle non-recoverable errors such as resource non-availability or some null Pointers.
未检查异常作为运行时exception类是理想的异常侯选处理不可恢复性出错,如资源不可用或者空指针。
Therefore, you know that an object has been declared finalizable and possibly, but not necessarily, collected, when the get method of the WeakReference or SoftReference class returns null.
这样,您就可以知道当WeakReference或softreference类的get方法返回null时,就有一个对象被声明为finalizable,而且可能(不过不一定)被收集。
If the parent returns null (or throws a ClassNotFoundException), then the class loader searches its own path for the source of the class.
如果父类返回null(或抛出ClassNotFoundException),那么类装入器会在自己的路径中寻找类的源。
The CompanySystemContractManager class in Listing 4 checks only if arguments or return values are null, but it's possible to enhance it to add extremely sophisticated checks.
清单4中的CompanySystemContractManager类只检查参数或者返回值是否为nulll,但是可以使其增强为加入特别复杂的检查。
In some cases, there may be no item class on an item, so null can be returned.
在某些情况下,条目中没有条目类,所以可以返回null。
Clear: Setting the reference object's referent field to null and declaring the object in the heap that the reference class referred to as finalizable.
清除:将引用对象的referent域设置为 null ,并将引用类在堆中引用的对象声明为 可结束的。
The default item class on a RepoItem is null, so the item class on all Folder objects in the example connector will also be null.
RepoItem 上的默认条目类是null,所以示例连接器中所有Folder对象上的条目类也是 null。
Unlike the dreaded null-pointer exception (which says nothing about what was expected to occur instead of the null pointer), a class-cast exception is relatively easy to debug.
与可怕的空指针异常(该异常除了报告空指针之外,对于将要发生的事情什么也不说)不同,类强制转换异常相对来说容易调试。
Unlike, for example, a class-cast exception, a null-pointer exception says nothing about what was expected instead of the null pointer.
例如,不像一个类转型异常,空指针异常不给出它所需要的内容的任何信息,只有一个空指针。
Instead, the error signaled at run time would be a null-pointer exception instead of a class-cast exception.
相反,在运行时发出的错误将会是一个空指针异常而不是类强制转换异常。
Why is the static variable null when I try to access it in another class?
为什么是静态变量空时,我尝试在另一个类的访问?
If an operation is declared with a null keyword, then the inheriting class can choose to override the null procedure.
如果某个操作宣布为带有null关键词,那么继承的类就可以选择忽略null程序。
What if someone inadvertently passes in a null value for the Class parameter?
如果有人不经意地为Class参数传入一个null值会怎么样呢?
For example, if the JVM cannot find a class required by custom code at test run time, IBM Rational Agent Controller will ignore the custom code and act as if it had returned null.
例如,如果在测试运行时jvm不能找到定制代码所需的类,那么IBMRationalAgentController将忽略定制代码并认为它应该返回null。
I was pleased to see that Xerces developer Tinny ng added this to the XMLString class and went a step further to null the string pointer (see Resources).
我高兴地看到Xerces开发者Tinnyng将它添加到了xmlstring类中,并更进一步设字符串指针为null(见参考资料)。
If the corresponding class, field, or method is not generic, a null value is passed when calling the method.
若相应的类、字段或方法非泛型,则在调用方法时将返回null值。
Also, many times member variables of a class that point to other classes simply need to be set to null at the appropriate time.
此外,您常常需要在适当的时候将指向其他类的类成员变量设置为null。
You might wonder about the String class given the issue of out-of-order writes and a reference becoming non-null prior to the constructor executing. Consider the following code.
鉴于无序写入和引用在构造函数执行前变成非null的问题,您可能会考虑string类。
Oops! You're greeted with the following error: Property [author] of class [class Entry] cannot be null.
您将看到以下错误:Property [author]ofclass [classEntry] can notbenull。
For fields without signatures, I'll just use a null value. Finally, the field type is an instance of the TypeDescription class, also shown in Listing 1.
对于没有签名的字段,将只使用null值。
Initialize, it can choose Null, the appointed name or the appointed class.
初始化,可以选择空、指定名称或指定的类。
First, by redefining the within class scatter matrix and the between class scatter matrix, a new null space method was presented.
首先,通过重新定义样本的类内散布矩阵和类间散布矩阵,提出了一种新的零空间法。
If it returns NULL, no window of that class is present.
如果返回值为NULL,表明当前没有这个依于这个类的窗口;
Why my class field is still pointing null after the initialization?
为什么我的班级仍然指向空后的初始化?
This paper is devoted to show the null exact controllability for a class of nonlocal parabolic equations with equiv-valued surface boundary condition.
本文讨论了具有等值面边界条件的抛物型方程的非局部的精确零能控性问题。
This paper is devoted to show the null exact controllability for a class of nonlocal parabolic equations with equiv-valued surface boundary condition.
本文讨论了具有等值面边界条件的抛物型方程的非局部的精确零能控性问题。
应用推荐