Tabnine Logo
Integer.shortValue
Code IndexAdd Tabnine to your IDE (free)

How to use
shortValue
method
in
java.lang.Integer

Best Java code snippets using java.lang.Integer.shortValue (Showing top 20 results out of 2,718)

origin: goldmansachs/gs-collections

  public short shortValueOf(Integer integer)
  {
    return integer.shortValue();
  }
}
origin: jfinal/jfinal

public Short toShort(Integer self) {
  return self.shortValue();
}
 
origin: eclipse/eclipse-collections

  @Override
  public short shortValueOf(Integer integer)
  {
    return integer.shortValue();
  }
}
origin: eclipse/eclipse-collections

  @Override
  public short shortValueOf(Integer integer)
  {
    return integer.shortValue();
  }
}
origin: linlinjava/litemall

public static Short parseShort(String body, String field) {
  ObjectMapper mapper = new ObjectMapper();
  JsonNode node = null;
  try {
    node = mapper.readTree(body);
    JsonNode leaf = node.get(field);
    if (leaf != null) {
      Integer value = leaf.asInt();
      return value.shortValue();
    }
  } catch (IOException e) {
    e.printStackTrace();
  }
  return null;
}
origin: org.apache.poi/poi

  @Override
  public void setDx2(int dx2) {
    _escherClientAnchor.setDx2(Integer.valueOf(dx2).shortValue());
  }
}
origin: drewnoakes/metadata-extractor

@Nullable
public String getPitchAngleDescription()
{
  Integer value = _directory.getInteger(TAG_PITCH_ANGLE);
  if (value == null)
    return null;
  DecimalFormat format = new DecimalFormat("0.#");
  // converted to degrees of upward camera tilt
  return format.format(-value.shortValue() / 10.0);
}
origin: drewnoakes/metadata-extractor

@Nullable
public String getRollAngleDescription()
{
  Integer value = _directory.getInteger(TAG_ROLL_ANGLE);
  if (value == null)
    return null;
  DecimalFormat format = new DecimalFormat("0.#");
  // converted to degrees of clockwise camera rotation
  return format.format(value.shortValue() / 10.0);
}
origin: drewnoakes/metadata-extractor

@Nullable
public String getAccelerometerZDescription()
{
  Integer value = _directory.getInteger(TAG_ACCELEROMETER_Z);
  if (value == null)
    return null;
  // positive is acceleration upwards
  return String.valueOf(value.shortValue());
}
origin: org.apache.poi/poi

/**
 * @param row2 the row(0 based) of the second cell.
 */
public void setRow2(int row2) {
  checkRange(row2, 0, MAX_ROW, "row2");
  _escherClientAnchor.setRow2(Integer.valueOf(row2).shortValue());
}
origin: drewnoakes/metadata-extractor

@Nullable
public String getAccelerometerXDescription()
{
  Integer value = _directory.getInteger(TAG_ACCELEROMETER_X);
  if (value == null)
    return null;
  // positive is acceleration to the left
  return String.valueOf(value.shortValue());
}
origin: org.apache.poi/poi

/**
 * @param row1 0-based row of the first cell.
 */
public void setRow1(int row1) {
  checkRange(row1, 0, MAX_ROW, "row1");
  _escherClientAnchor.setRow1(Integer.valueOf(row1).shortValue());
}
origin: drewnoakes/metadata-extractor

@Nullable
public String getAccelerometerYDescription()
{
  Integer value = _directory.getInteger(TAG_ACCELEROMETER_Y);
  if (value == null)
    return null;
  // positive is acceleration backwards
  return String.valueOf(value.shortValue());
}
origin: eclipse-vertx/vert.x

public StreamPriority(JsonObject json) {
 this.weight = json.getInteger("weight", (int)DEFAULT_WEIGHT).shortValue();
 this.dependency = json.getInteger("dependency", DEFAULT_DEPENDENCY);
 this.exclusive = json.getBoolean("exclusive", DEFAULT_EXCLUSIVE);
}
origin: org.postgresql/postgresql

public short getShort(int parameterIndex) throws SQLException {
 checkClosed();
 checkIndex(parameterIndex, Types.SMALLINT, "Short");
 if (callResult[parameterIndex - 1] == null) {
  return 0;
 }
 return ((Integer) callResult[parameterIndex - 1]).shortValue();
}
origin: apache/flink

  @Override
  protected Short[] getSortedTestData() {
    Random rnd = new Random(874597969123412338L);
    short rndShort = Integer.valueOf(rnd.nextInt()).shortValue();
    if (rndShort < 0) {
      rndShort = Integer.valueOf(-rndShort).shortValue();
    }
    if (rndShort == Short.MAX_VALUE) {
      rndShort -= 3;
    }
    if (rndShort <= 2) {
      rndShort += 3;
    }
    return new Short[]{
      Short.valueOf(Short.MIN_VALUE),
      Short.valueOf(Integer.valueOf(-rndShort).shortValue()),
      Short.valueOf(Integer.valueOf(-1).shortValue()),
      Short.valueOf(Integer.valueOf(0).shortValue()),
      Short.valueOf(Integer.valueOf(1).shortValue()),
      Short.valueOf(Integer.valueOf(2).shortValue()),
      Short.valueOf(Integer.valueOf(rndShort).shortValue()),
      Short.valueOf(Short.MAX_VALUE)};
  }
}
origin: drewnoakes/metadata-extractor

@Nullable
public String getWbTypeDescription(int tagType)
{
  Integer wbtype = _directory.getInteger(tagType);
  if (wbtype == null)
    return null;
  return super.getLightSourceDescription(wbtype.shortValue());
}
origin: drewnoakes/metadata-extractor

  @Nullable
  public String getWbTypeDescription(int tagType)
  {
    Integer wbtype = _directory.getInteger(tagType);
    if (wbtype == null)
      return null;

    return super.getLightSourceDescription(wbtype.shortValue());
  }
}
origin: drewnoakes/metadata-extractor

  @Nullable
  public String getWbTypeDescription(int tagType)
  {
    Integer wbtype = _directory.getInteger(tagType);
    if (wbtype == null)
      return null;

    return super.getLightSourceDescription(wbtype.shortValue());
  }
}
origin: apache/flink

  @Override
  protected ShortValue[] getSortedTestData() {
    Random rnd = new Random(874597969123412338L);
    short rndShort = Integer.valueOf(rnd.nextInt()).shortValue();
    if (rndShort < 0) {
      rndShort = Integer.valueOf(-rndShort).shortValue();
    }
    if (rndShort == Short.MAX_VALUE) {
      rndShort -= 3;
    }
    if (rndShort <= 2) {
      rndShort += 3;
    }
    return new ShortValue[]{
      new ShortValue(Short.MIN_VALUE),
      new ShortValue(Integer.valueOf(-rndShort).shortValue()),
      new ShortValue(Integer.valueOf(-1).shortValue()),
      new ShortValue(Integer.valueOf(0).shortValue()),
      new ShortValue(Integer.valueOf(1).shortValue()),
      new ShortValue(Integer.valueOf(2).shortValue()),
      new ShortValue(Integer.valueOf(rndShort).shortValue()),
      new ShortValue(Short.MAX_VALUE)};
  }
}
java.langIntegershortValue

Javadoc

Returns the value of this Integer as a short.

Popular methods of Integer

  • parseInt
    Parses the specified string as a signed integer value using the specified radix. The ASCII character
  • toString
    Converts the specified signed integer into a string representation based on the specified radix. The
  • valueOf
    Parses the specified string as a signed integer value using the specified radix.
  • intValue
    Gets the primitive value of this int.
  • <init>
    Constructs a new Integer from the specified string.
  • toHexString
    Returns a string representation of the integer argument as an unsigned integer in base 16.The unsign
  • equals
    Compares this instance with the specified object and indicates if they are equal. In order to be equ
  • compareTo
    Compares this Integer object to another object. If the object is an Integer, this function behaves l
  • hashCode
  • compare
    Compares two int values.
  • longValue
    Returns the value of this Integer as along.
  • decode
    Parses the specified string and returns a Integer instance if the string can be decoded into an inte
  • longValue,
  • decode,
  • numberOfLeadingZeros,
  • getInteger,
  • doubleValue,
  • toBinaryString,
  • byteValue,
  • bitCount,
  • highestOneBit

Popular in Java

  • Start an intent from android
  • notifyDataSetChanged (ArrayAdapter)
  • getContentResolver (Context)
  • findViewById (Activity)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • Connection (java.sql)
    A connection represents a link from a Java application to a database. All SQL statements and results
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • HttpServletRequest (javax.servlet.http)
    Extends the javax.servlet.ServletRequest interface to provide request information for HTTP servlets.
  • DateTimeFormat (org.joda.time.format)
    Factory that creates instances of DateTimeFormatter from patterns and styles. Datetime formatting i
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now