In this tutorial, you will see the use of hashCode() in short buffer.
In this tutorial, you will see the use of hashCode() in short buffer.ShortBuffer API:
The java.nio.ShortBuffer class extends java.nio.Buffer class. It provides the following methods:
Return type | Method | Description |
static ShortBuffer | allocate(int capacity) | The allocate(..)method allocate a new short buffer. |
abstract ShortBuffer | put(short s) | The put(..) method write short value in short buffer. |
final int | hashCode() | The hashCode(..) method returns current hash Code of buffer. |
import java.nio.*;
|
C:\>java
ShortBuffHasCode Before writing content the current hash code of buffer : 1794185345 After writing content the current hash code of buffer : 2253 |