Java Integer Create toInt(char msc, char lsc)

Here you can find the source of toInt(char msc, char lsc)

Description

joining 2 chars to form an int

License

Open Source License

Parameter

Parameter Description
msc most significant char
lsc least significant char

Return

int form

Declaration

static int toInt(char msc, char lsc) 

Method Source Code

//package com.java2s;

public class Main {
    /**/*from  w  ww . j av  a 2  s  .  co m*/
     * joining 2 chars to form an int
     * @param msc most significant char
     * @param lsc least significant char
     * @return int form
     */
    static int toInt(char msc, char lsc) {
        return ((msc << 16) | lsc);
    }
}

Related

  1. toInt(byte[] src)
  2. toInt(byte[] src)
  3. toInt(byte[] src, int srcPos)
  4. toInt(byte[] value)
  5. toInt(byte[] value)
  6. toInt(char[] bytes, boolean le)
  7. toInt(double d)
  8. toInt(double d)
  9. toInt(double d)