| java.lang.Object | |
| ↳ | java.lang.Short |
The Short class is the standard wrapper for short values.
| Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| short | MAX_VALUE | The maximum value a Short can have. | |||||||||
| short | MIN_VALUE | The minimum value a Short can have. | |||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
|
Short(short value)
Constructs a Short object initialized to the specified short value.
| |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| boolean |
equals(Object obj)
Compares this object to the specified object.
| ||||||||||
| int |
hashCode()
Returns a hashcode for this Short.
| ||||||||||
| static short |
parseShort(String s)
Assuming the specified String represents a short, returns that short's value.
| ||||||||||
| static short |
parseShort(String s, int radix)
Assuming the specified String represents a short, returns that short's value.
| ||||||||||
| short |
shortValue()
Returns the value of this Short as a short.
| ||||||||||
| String |
toString()
Returns a String object representing this Short's value.
| ||||||||||
| static Short | valueOf(short b) | ||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
The maximum value a Short can have.
The minimum value a Short can have.
Constructs a Short object initialized to the specified short value.
| value | the initial value of the Short |
|---|
Compares this object to the specified object.
| obj | the object to compare with |
|---|
Returns a hashcode for this Short.
Assuming the specified String represents a short, returns that short's value. Throws an exception if the String cannot be parsed as a short. The radix is assumed to be 10.
| s | the String containing the short |
|---|
| NumberFormatException | If the string does not contain a parsable short. |
|---|
Assuming the specified String represents a short, returns that short's value. Throws an exception if the String cannot be parsed as a short.
| s | the String containing the short |
|---|---|
| radix | the radix to be used |
| NumberFormatException | If the String does not contain a parsable short. |
|---|
Returns the value of this Short as a short.
Returns a String object representing this Short's value.