What is the translation of " HASHCODE " in Chinese?

一个hashcode

Examples of using Hashcode in English and their translations into Chinese

{-}
  • Political category close
  • Ecclesiastic category close
  • Programming category close
Why hashcode will be cached?
那么为什么要覆盖hashCode呢??
It prints its element type and hashcode as shown below.
它打印其元素类型和哈希代码,如下所示。
Generally a hashcode value will be the memory address of the object.
通常,一个hashcode值会是对象的内存地址。
Integers are also good because their hashcode is their own value.
整形也不错,因为它的哈希值就是他们自己本身的值。
The equals and hashcode are methods defined in the Object class.
Equals方法、hashCode方法被定义在Object类中。
This class does not implement own equals and hashCode methods.
该机制并不基于实体类中的equals和hashcode方法。
Hashcode is used for bucketing in Hash implementations like HashMap, HashTable, HashSet etc.
Hashcode值主要用于基于散列的集合,如HashMap,HashSet,HashTable…etc。
When you override equals() you must also override hashcode().
注意:如果你重载equals(),你也必须重载hashCode()。
Being immutable guarantees that hashcode will always be the same so that it can be cashed without worrying about the changes.
不可变保证哈希码总是相同的,这样它就可以缓存起来而不用担心变化。
When overriding equals() you should also override hashCode().
注意:如果你重载equals(),你也必须重载hashCode()。
Since String is immutable, its hashcode is cached at the time of creation and it doesn't need to be calculated again.
因为字符串是不可变的,所以在它创建的时候hashCode就被缓存了,不需要重新计算。
Also, the name is a string,so it has already a cached hashCode() value inside.
而且name是个字符串,所以它已经在内部缓存了hashCode()的值。
A hashCode method must return the same value during the same run of a program but not necessarily from one program run to another.
一个hashCode方法在一个程序的同样运行下一定会返回同样的值,但在不同运行下不一定会。
Say goodbye to the boilerplate code of setter/getter, hashcode/equals, constructors/toString.
和setter/getter、hashcode/equals以及constructors/toString这样的模板代码说再见。
Note: if you define a Set of composite elements,it is very important to implement equals() and hashCode().
注意,如果你决定定义一个元素是联合元素的Set,正确地实现equals()和hashCode()是非常重要的。
Because these classes are immutable and implement hashCode() and equals() sensibly, they all make good hash keys.
由于这些类都是不可修改的并且可以实施hashCode()和equals(),它们都可以做为很好的散列关键字。
Note: if you define a Set of composite elements,it is very important to implement equals() and hashCode().
注意,如果你定义的Set包含组合元素(composite-element),正确地实现equals()和hashCode()是非常重要的。
Being immutable guarantees that hashcode will always be the same so that it can be cashed without worrying about the changes.
字符串的不可变性保证hashcode始终相同,所以hashcode可以被缓存而不用担心字符串被修改。
I started by defining a simple Java class with a few fields, toString,equals, hashCode etc. It was about 50 lines of code.
我从定义一个简单的Java类开始,这个类包括一些字段、toString、equals、hashCode等,大约写了50行代码。
Similarly, the default implementation of hashCode() provided by Object is derived by mapping the memory address of the object to an integer value.
同样,Object提供的hashCode()的缺省实施通过将对象的内存地址对映于一个整数值来生成。
Depending on your class,you may also want to delegate part of the computation to the equals() or hashCode() function of the superclass.
根据您使用的类,您可能希望降低superclass的equals()或hashCode()功能一部分计算能力。
For more complex classes, the behavior of equals() and hashCode() may even be imposed by the specification of a superclass or interface.
对于比较复杂的类来说,equals()和hashCode()的行为可能甚至受到superclass或interface的影响。
In Kotlin, you can simply use data classes instead,where the compiler automatically derives methods like equals(), hashCode() and many more.
在Kotlin中,你可以简单地使用数据类,编译器会自动派生equals()和hashCode()等方法。
There are some restrictions placed on the behavior of equals() and hashCode(), which are enumerated in the documentation for Object.
实施equals()和hashCode()有一些限制,Object文件中列举出了这些限制。
The requirements for hashCode() are defined with even more specificity-- the hashCode() value of a list must conform to the following calculation:.
HashCode()的需求更特殊--list的hashCode()值必须符合以下计算:.
If you override the equals()method, you change the way two objects are equated andObject's implementation of hashCode()is no longer valid.
如果重载equals()方法,则可以改变两个对象的等同方式,并且Object的hashCode()实现不再有效。
Case classes eliminate all noise fromvalue objects as well(like equals and hashCode implementations) and simultaneously cut down a common source of errors.
Case类还消除了值对象的所有干扰(像equals和hashCode实现),并同时减少了常见错误来源。
String in immutable means,no one can change its contents once created and which guarantee the hashcode of string to be same in multiple invocation.
简而言之,因为String是不可变的,所以没有人可以在创建后更改其内容,这保证了String的hashCode在多次调用时是相同的。
An identity-based implementation for equals() and hashCode() is a sensible default, but for some classes, it is desirable to relax the definition of equality somewhat.
缺省情况下,equals()和hashCode()基于标识的实施是合理的,但对于某些类来说,它们希望放宽等式的定义。
To be on the safe side, let the Eclipse IDE generate the equals and hashCode functions as a pair: Sourcegt; Generate hashCode() and equals()….".
出于安全起见,EclipseIDE将equals和hashCode作为成对的选项出现:Sourcegt;GeneratehashCode()andequals()…….
Results: 80, Time: 0.0258

Top dictionary queries

English - Chinese