亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bigdecimal.java

?? java源代碼 請看看啊 提點寶貴的意見
?? JAVA
?? 第 1 頁 / 共 3 頁
字號:
     *	       maintain its overall value.     * @throws ArithmeticException <tt>scale</tt> is negative, or     * 	       the specified scaling operation would require rounding.     * @see    #setScale(int, int)     */    public BigDecimal setScale(int scale) {	return setScale(scale, ROUND_UNNECESSARY);    }    // Decimal Point Motion Operations    /**     * Returns a BigDecimal which is equivalent to this one with the decimal     * point moved n places to the left.  If n is non-negative, the call merely     * adds n to the scale.  If n is negative, the call is equivalent to     * movePointRight(-n).  (The BigDecimal returned by this call has value     * <tt>(this * 10<sup>-n</sup>)</tt> and scale     * <tt>max(this.scale()+n, 0)</tt>.)     *     * @param  n number of places to move the decimal point to the left.     * @return a BigDecimal which is equivalent to this one with the decimal     *	       point moved <tt>n</tt> places to the left.     */    public BigDecimal movePointLeft(int n){	return (n>=0 ? new BigDecimal(intVal, scale+n) : movePointRight(-n));    }    /**     * Moves the decimal point the specified number of places to the right.     * If this BigDecimal's scale is &gt;= <tt>n</tt>, the call merely     * subtracts <tt>n</tt> from the scale; otherwise, it sets the scale to     * zero, and multiplies the integer value by     * <tt>10<sup>(n - this.scale)</sup></tt>.  If <tt>n</tt>     * is negative, the call is equivalent to <tt>movePointLeft(-n)</tt>. (The     * BigDecimal returned by this call has value     * <tt>(this * 10<sup>n</sup>)</tt> and scale     * <tt>max(this.scale()-n, 0)</tt>.)     *     * @param  n number of places to move the decimal point to the right.     * @return a BigDecimal which is equivalent to this one with the decimal     *         point moved <tt>n</tt> places to the right.     */    public BigDecimal movePointRight(int n){	return (scale >= n ? new BigDecimal(intVal, scale-n)		           : new BigDecimal(timesTenToThe(intVal, n-scale),0));    }    // Comparison Operations    /**     * Compares this BigDecimal with the specified BigDecimal.   Two     * BigDecimals that are equal in value but have a different scale (like     * 2.0 and 2.00) are considered equal by this method.  This method is     * provided in preference to individual methods for each of the six     * boolean comparison operators (&lt;, ==, &gt;, &gt;=, !=, &lt;=).  The     * suggested idiom for performing these comparisons is:     * <tt>(x.compareTo(y)</tt> &lt;<i>op</i>&gt; <tt>0)</tt>,     * where &lt;<i>op</i>&gt; is one of the six comparison operators.     *     * @param  val BigDecimal to which this BigDecimal is to be compared.     * @return -1, 0 or 1 as this BigDecimal is numerically less than, equal     *         to, or greater than <tt>val</tt>.     */    public int compareTo(BigDecimal val){	/* Optimization: would run fine without the next three lines */	int sigDiff = signum() - val.signum();	if (sigDiff != 0)	    return (sigDiff > 0 ? 1 : -1);	/* If signs match, scale and compare intVals */	BigDecimal arg[] = new BigDecimal[2];	arg[0] = this;	arg[1] = val;	matchScale(arg);	return arg[0].intVal.compareTo(arg[1].intVal);    }    /**     * Compares this BigDecimal with the specified Object.  If the Object is a     * BigDecimal, this method behaves like {@link #compareTo compareTo}.     * Otherwise, it throws a <tt>ClassCastException</tt> (as BigDecimals are     * comparable only to other BigDecimals).     *     * @param  o Object to which this BigDecimal is to be compared.     * @return a negative number, zero, or a positive number as this     *	       BigDecimal is numerically less than, equal to, or greater     *	       than <tt>o</tt>, which must be a BigDecimal.     * @throws ClassCastException <tt>o</tt> is not a BigDecimal.     * @see    #compareTo(java.math.BigDecimal)     * @see    Comparable     * @since  1.2     */    public int compareTo(Object o) {	return compareTo((BigDecimal)o);    }    /**     * Compares this BigDecimal with the specified Object for     * equality.  Unlike {@link #compareTo compareTo}, this method     * considers two BigDecimals equal only if they are equal in value     * and scale (thus 2.0 is not equal to 2.00 when compared by this     * method).     *     * @param  x Object to which this BigDecimal is to be compared.     * @return <tt>true</tt> if and only if the specified Object is a     *	       BigDecimal whose value and scale are equal to this BigDecimal's.     * @see    #compareTo(java.math.BigDecimal)     */    public boolean equals(Object x){	if (!(x instanceof BigDecimal))	    return false;	BigDecimal xDec = (BigDecimal) x;	return scale == xDec.scale && intVal.equals(xDec.intVal);    }    /**     * Returns the minimum of this BigDecimal and <tt>val</tt>.     *     * @param  val value with which the minimum is to be computed.     * @return the BigDecimal whose value is the lesser of this BigDecimal and      *	       <tt>val</tt>.  If they are equal, as defined by the     * 	       {@link #compareTo compareTo} method, either may be returned.     * @see    #compareTo(java.math.BigDecimal)     */    public BigDecimal min(BigDecimal val){	return (compareTo(val)<0 ? this : val);    }    /**     * Returns the maximum of this BigDecimal and <tt>val</tt>.     *     * @param  val value with which the maximum is to be computed.     * @return the BigDecimal whose value is the greater of this BigDecimal     *	       and <tt>val</tt>.  If they are equal, as defined by the     * 	       {@link #compareTo compareTo} method, either may be returned.     * @see    #compareTo(java.math.BigDecimal)     */    public BigDecimal max(BigDecimal val){	return (compareTo(val)>0 ? this : val);    }    // Hash Function    /**     * Returns the hash code for this BigDecimal.  Note that two BigDecimals     * that are numerically equal but differ in scale (like 2.0 and 2.00)     * will generally <i>not</i> have the same hash code.     *     * @return hash code for this BigDecimal.     */    public int hashCode() {	return 31*intVal.hashCode() + scale;    }    //    // add one to the least significant digit.    // in the unlikely event there is a carry out,    // deal with it.    //    private String    roundup(String val){	int i;        char[] digits = val.toCharArray();        int nDigits = digits.length;        	int q = digits[ i = (nDigits-1)];	if ( q == '9' ){	    while ( q == '9' && i > 0 ){		digits[i] = '0';		q = digits[--i];	    }	    if ( q == '9' ){		// carryout! High-order 1, rest 0s, larger exp.		digits[0] = '0';		return "1" + String.valueOf(digits);	    }	    // else fall through.	}	digits[i] = (char)(q+1);        return String.valueOf(digits);    }    // Format Converters    /**     * Returns the string representation of this BigDecimal.  The digit-to-     * character mapping provided by {@link Character#forDigit} is used.     * A leading minus sign is used to indicate sign, and the number of digits     * to the right of the decimal point is used to indicate scale.  (This     * representation is compatible with the (String) constructor.)     *     * @return String representation of this BigDecimal.     * @see    Character#forDigit     * @see    #BigDecimal(java.lang.String)     */    public String toString(){	if (scale == 0)	/* No decimal point */	    return intVal.toString();        return getValueString(signum(), intVal.abs().toString(), scale);    }    /**     * Converts this BigDecimal to a BigInteger.  This conversion is     * analogous to a <a     * href="http://java.sun.com/docs/books/jls/second_edition/html/conversions.doc.html#25363"><i>narrowing     * primitive conversion</i></a> from <code>double</code> to     * <code>long</code> as defined in the <a     * href="http://java.sun.com/docs/books/jls/html/">Java Language     * Specification</a>: any fractional part of this BigDecimal will     * be discarded.  Note that this conversion can lose information     * about the precision of the BigDecimal value.     *     * @return this BigDecimal converted to a BigInteger.     */    public BigInteger toBigInteger() {	return (scale==0 ? intVal			 : intVal.divide(BigInteger.valueOf(10).pow(scale)));    }    /**     * Converts this BigDecimal to an <code>int</code>.  This     * conversion is analogous to a <a     * href="http://java.sun.com/docs/books/jls/second_edition/html/conversions.doc.html#25363"><i>narrowing     * primitive conversion</i></a> from <code>double</code> to     * <code>short</code> as defined in the <a     * href="http://java.sun.com/docs/books/jls/html/">Java Language     * Specification</a>: any fractional part of this BigDecimal will     * be discarded, and if the resulting &quot;BigInteger&quot; is     * too big to fit in an <code>int</code>, only the low-order 32     * bits are returned.  Note that this conversion can lose     * information about the overall magnitude and precision of the     * BigDecimal value as well as return a result with the opposite     * sign.     *      * @return this BigDecimal converted to an <code>int</code>.     */    public int intValue(){	return toBigInteger().intValue();    }    /**     * Converts this BigDecimal to a <code>long</code>.  This     * conversion is analogous to a <a     * href="http://java.sun.com/docs/books/jls/second_edition/html/conversions.doc.html#25363"><i>narrowing     * primitive conversion</i></a> from <code>double</code> to     * <code>short</code> as defined in the <a     * href="http://java.sun.com/docs/books/jls/html/">Java Language     * Specification</a>: any fractional part of this BigDecimal will     * be discarded, and if the resulting &quot;BigInteger&quot; is     * too big to fit in a <code>long</code>, only the low-order 64     * bits are returned.  Note that this conversion can lose     * information about the overall magnitude and precision of the     * BigDecimal value as well as return a result with the opposite     * sign.     *      * @return this BigDecimal converted to an <code>long</code>.     */    public long longValue(){	return toBigInteger().longValue();    }    /**     * Converts this BigDecimal to a <code>float</code>.  This     * conversion is similar to the <a     * href="http://java.sun.com/docs/books/jls/second_edition/html/conversions.doc.html#25363"><i>narrowing     * primitive conversion</i></a> from <code>double</code> to     * <code>float</code> defined in the <a     * href="http://java.sun.com/docs/books/jls/html/">Java Language     * Specification</a>: if this BigDecimal has too great a magnitude     * to represent as a <code>float</code>, it will be converted to     * {@link Float#NEGATIVE_INFINITY} or {@link     * Float#POSITIVE_INFINITY} as appropriate.  Note that even when     * the return value is finite, this conversion can lose     * information about the precision of the BigDecimal value.     *      * @return this BigDecimal converted to a <code>float</code>.     */    public float floatValue(){	/* Somewhat inefficient, but guaranteed to work. */	return Float.valueOf(this.toString()).floatValue();    }    /**     * Converts this BigDecimal to a <code>double</code>.  This     * conversion is similar to the <a     * href="http://java.sun.com/docs/books/jls/second_edition/html/conversions.doc.html#25363"><i>narrowing     * primitive conversion</i></a> from <code>double</code> to     * <code>float</code> as defined in the <a     * href="http://java.sun.com/docs/books/jls/html/">Java Language     * Specification</a>: if this BigDecimal has too great a magnitude     * represent as a <code>double</code>, it will be converted to     * {@link Double#NEGATIVE_INFINITY} or {@link     * Double#POSITIVE_INFINITY} as appropriate.  Note that even when     * the return value is finite, this conversion can lose     * information about the precision of the BigDecimal value.     *      * @return this BigDecimal converted to a <code>double</code>.     */    public double doubleValue(){	/* Somewhat inefficient, but guaranteed to work. */	return Double.valueOf(this.toString()).doubleValue();    }    // Private "Helper" Methods        /* Returns a digit.digit string */    private String getValueString(int signum, String intString, int scale) { 	/* Insert decimal point */ 	StringBuffer buf; 	int insertionPoint = intString.length() - scale; 	if (insertionPoint == 0) {  /* Point goes right before intVal */ 	    return (signum<0 ? "-0." : "0.") + intString; 	} else if (insertionPoint > 0) { /* Point goes inside intVal */ 	    buf = new StringBuffer(intString); 	    buf.insert(insertionPoint, '.'); 	    if (signum < 0) 		buf.insert(0, '-'); 	} else { /* We must insert zeros between point and intVal */ 	    buf = new StringBuffer(3-insertionPoint + intString.length()); 	    buf.append(signum<0 ? "-0." : "0."); 	    for (int i=0; i<-insertionPoint; i++) 		buf.append('0'); 	    buf.append(intString); 	} 	return buf.toString();    }        /* Returns (a * 10^b) */    private static BigInteger timesTenToThe(BigInteger a, int b) {	return a.multiply(BigInteger.valueOf(10).pow(b));    }    /*     * If the scales of val[0] and val[1] differ, rescale (non-destructively)     * the lower-scaled BigDecimal so they match.     */    private static void matchScale(BigDecimal[] val) {	if (val[0].scale < val[1].scale)	    val[0] = val[0].setScale(val[1].scale);	else if (val[1].scale < val[0].scale)	    val[1] = val[1].setScale(val[0].scale);    }    /**     * Reconstitute the <tt>BigDecimal</tt> instance from a stream (that is,     * deserialize it).     */    private synchronized void readObject(java.io.ObjectInputStream s)        throws java.io.IOException, ClassNotFoundException {        // Read in all fields	s.defaultReadObject();        // Validate scale factor        if (scale < 0)	    throw new java.io.StreamCorruptedException(                                      "BigDecimal: Negative scale");    }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色狠狠色狠狠综合| 蜜桃在线一区二区三区| 高清不卡一区二区在线| 国产精品女主播av| 色欧美片视频在线观看| 亚洲一二三四在线观看| 欧美精品tushy高清| 日本怡春院一区二区| 精品嫩草影院久久| 国产成人高清在线| 亚洲欧美偷拍三级| 在线成人免费视频| 国产精品自产自拍| 亚洲欧洲国产专区| 欧美亚洲另类激情小说| 日本欧美一区二区| 国产欧美综合在线观看第十页| 成人在线视频首页| 亚洲综合精品久久| 日韩免费高清电影| 成人国产视频在线观看| 亚洲国产毛片aaaaa无费看| 日韩视频一区二区三区在线播放| 狠狠色综合日日| 一区二区视频免费在线观看| 欧美一级片在线看| 国产91对白在线观看九色| 亚洲综合av网| 久久日一线二线三线suv| 色综合天天综合网天天狠天天| 午夜精品一区二区三区免费视频 | 蓝色福利精品导航| 国产精品天干天干在线综合| 欧美三级三级三级| 国产成人精品影视| 青青草视频一区| 亚洲欧美日韩电影| www日韩大片| 欧美三级乱人伦电影| 国产成人综合网站| 天堂久久久久va久久久久| 欧美国产视频在线| 欧美一区二区三区性视频| 成人av网站免费观看| 美国欧美日韩国产在线播放| 亚洲精品日韩综合观看成人91| 日韩精品一区二区三区中文精品| 91蜜桃免费观看视频| 国产在线播精品第三| 天天色天天爱天天射综合| 亚洲视频1区2区| 久久久久久久精| 欧美精品 国产精品| 94色蜜桃网一区二区三区| 黄色日韩网站视频| 免费av网站大全久久| 亚洲高清免费观看高清完整版在线观看| 国产欧美精品一区二区三区四区 | 国产一区二区三区免费播放| 亚洲国产精品麻豆| 一区二区在线观看不卡| 国产欧美一区二区在线| 91精品免费观看| 欧美日韩午夜在线| 欧美亚洲免费在线一区| 色欲综合视频天天天| 99re6这里只有精品视频在线观看 99re8在线精品视频免费播放 | 免费成人在线影院| 午夜精品久久久久| 亚洲一区国产视频| 亚洲综合在线电影| 亚洲一区二区在线观看视频 | 久久综合色8888| 欧美成人精品1314www| 91精品久久久久久蜜臀| 欧美情侣在线播放| 欧美丰满少妇xxxbbb| 7777精品伊人久久久大香线蕉的| 精品视频999| 欧美亚洲自拍偷拍| 欧美乱妇一区二区三区不卡视频| 欧美日韩一区二区三区在线 | 欧美日韩mp4| 欧美一区二区在线看| 欧美一区二区三区四区在线观看 | 欧美乱熟臀69xxxxxx| 91精品国产综合久久久蜜臀粉嫩 | 久久综合久久久久88| 久久网站最新地址| 国产日本欧美一区二区| 国产精品久久久久久久浪潮网站| 国产精品青草综合久久久久99| 国产精品久久久久一区二区三区共| 国产精品欧美一区喷水| 亚洲美女视频一区| 亚洲不卡av一区二区三区| 日韩 欧美一区二区三区| 久久av中文字幕片| 成人精品鲁一区一区二区| 91亚洲精品一区二区乱码| 欧美体内she精高潮| 欧美一级久久久| 久久蜜桃av一区二区天堂| 亚洲欧美一区二区视频| 亚洲五码中文字幕| 日本大胆欧美人术艺术动态| 国内成人免费视频| 91免费版在线| 欧美一区二区三区小说| 国产无遮挡一区二区三区毛片日本| 国产精品久久久久久久久免费桃花| 亚洲主播在线播放| 精品一区中文字幕| 色综合天天综合网天天看片| 欧美精品第1页| 国产精品美女一区二区在线观看| 亚洲综合在线五月| 国产精品1区二区.| 欧美日韩精品一区二区在线播放| 久久亚洲影视婷婷| 一区二区三区中文字幕在线观看| 久久精品国产亚洲a| 97超碰欧美中文字幕| 91精品国产综合久久久蜜臀图片 | 日本精品一级二级| 精品久久久久久综合日本欧美| 亚洲欧洲av色图| 奇米精品一区二区三区在线观看| 成人免费观看视频| 欧美一区二区三区在线观看 | 国产精品久久久久一区二区三区共 | 色综合久久久久综合| 国产成人综合在线播放| 久久先锋影音av鲁色资源网| 亚洲欧美成aⅴ人在线观看| 亚洲欧美激情在线| 久久国产麻豆精品| 色婷婷精品大在线视频| 国产午夜精品一区二区三区四区| 日韩黄色免费网站| 欧洲精品一区二区| 中文字幕一区二区三区四区不卡 | 色哟哟精品一区| 久久精品无码一区二区三区| 视频一区二区三区在线| 一本色道久久综合亚洲精品按摩| 国产亚洲精品久| 韩国欧美国产1区| 欧美日本在线看| 亚洲影院免费观看| av亚洲精华国产精华| 久久女同性恋中文字幕| 精彩视频一区二区| 69精品人人人人| 亚洲h在线观看| 欧美性受极品xxxx喷水| 亚洲蜜臀av乱码久久精品| 成人久久久精品乱码一区二区三区 | 亚洲欧美日韩国产另类专区| 成人影视亚洲图片在线| 久久精品视频免费观看| 久久99国产精品久久| 欧美一级高清片在线观看| 舔着乳尖日韩一区| 欧美色男人天堂| 亚洲一区二区三区在线看| 91老师国产黑色丝袜在线| 亚洲国产精品二十页| 国产不卡视频在线观看| 久久久久国产精品麻豆ai换脸| 美洲天堂一区二卡三卡四卡视频| 欧美电影在哪看比较好| 日韩综合一区二区| 91精品国产综合久久精品性色| 午夜欧美2019年伦理| 91 com成人网| 久久不见久久见免费视频7 | 日韩二区三区四区| 欧美一区二区三区在| 久久成人18免费观看| 久久久久国产免费免费| 99re8在线精品视频免费播放| 亚洲三级电影网站| 精品视频一区二区不卡| 五月婷婷欧美视频| 精品国免费一区二区三区| 国产精品综合av一区二区国产馆| 国产欧美一区二区三区在线看蜜臀 | 成人精品视频一区| 亚洲六月丁香色婷婷综合久久| 欧美在线高清视频| 免费观看一级特黄欧美大片| 久久综合久久久久88| 91一区一区三区| 日韩精品福利网| 国产视频一区在线观看| 色香色香欲天天天影视综合网| 日本欧洲一区二区| 久久久www成人免费毛片麻豆| 99国产欧美另类久久久精品|