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

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

?? millisecond.java

?? jfreechart1.0.1 jsp繪制圖表的開發(fā)包
?? JAVA
字號:
/* ===========================================================
 * JFreeChart : a free chart library for the Java(tm) platform
 * ===========================================================
 *
 * (C) Copyright 2000-2005, by Object Refinery Limited and Contributors.
 *
 * Project Info:  http://www.jfree.org/jfreechart/index.html
 *
 * This library is free software; you can redistribute it and/or modify it 
 * under the terms of the GNU Lesser General Public License as published by 
 * the Free Software Foundation; either version 2.1 of the License, or 
 * (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful, but 
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 
 * License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, 
 * USA.  
 *
 * [Java is a trademark or registered trademark of Sun Microsystems, Inc. 
 * in the United States and other countries.]
 *
 * ----------------
 * Millisecond.java
 * ----------------
 * (C) Copyright 2001-2005, by Object Refinery Limited.
 *
 * Original Author:  David Gilbert (for Object Refinery Limited);
 * Contributor(s):   -;
 *
 * $Id: Millisecond.java,v 1.5.2.1 2005/10/25 21:35:24 mungady Exp $
 *
 * Changes
 * -------
 * 11-Oct-2001 : Version 1 (DG);
 * 19-Dec-2001 : Added new constructors as suggested by Paul English (DG);
 * 26-Feb-2002 : Added new getStart() and getEnd() methods (DG);
 * 29-Mar-2002 : Fixed bug in getStart(), getEnd() and compareTo() methods (DG);
 * 10-Sep-2002 : Added getSerialIndex() method (DG);
 * 07-Oct-2002 : Fixed errors reported by Checkstyle (DG);
 * 10-Jan-2003 : Changed base class and method names (DG);
 * 13-Mar-2003 : Moved to com.jrefinery.data.time package and implemented 
 *               Serializable (DG);
 * 21-Oct-2003 : Added hashCode() method (DG);
 *
 */

package org.jfree.data.time;

import java.io.Serializable;
import java.util.Calendar;
import java.util.Date;
import java.util.TimeZone;

/**
 * Represents a millisecond.  This class is immutable, which is a requirement 
 * for all {@link RegularTimePeriod} subclasses.
 */
public class Millisecond extends RegularTimePeriod implements Serializable {

    /** For serialization. */
    static final long serialVersionUID = -5316836467277638485L;
    
    /** A constant for the first millisecond in a second. */
    public static final int FIRST_MILLISECOND_IN_SECOND = 0;

    /** A constant for the last millisecond in a second. */
    public static final int LAST_MILLISECOND_IN_SECOND = 999;

    /** The millisecond. */
    private int millisecond;

    /** The second. */
    private Second second;

    /**
     * Constructs a millisecond based on the current system time.
     */
    public Millisecond() {
        this(new Date());
    }

    /**
     * Constructs a millisecond.
     *
     * @param millisecond  the millisecond (0-999).
     * @param second  the second.
     */
    public Millisecond(int millisecond, Second second) {
        this.millisecond = millisecond;
        this.second = second;
    }

    /**
     * Creates a new millisecond.
     * 
     * @param millisecond  the millisecond (0-999).
     * @param second  the second (0-59).
     * @param minute  the minute (0-59).
     * @param hour  the hour (0-23).
     * @param day  the day (1-31).
     * @param month  the month (1-12).
     * @param year  the year (1900-9999).
     */    
    public Millisecond(int millisecond, int second, int minute, int hour,
                       int day, int month, int year) {
                           
        this(millisecond, new Second(second, minute, hour, day, month, year));
    
    }

    /**
     * Constructs a millisecond.
     *
     * @param time  the time.
     */
    public Millisecond(Date time) {
        this(time, RegularTimePeriod.DEFAULT_TIME_ZONE);
    }

    /**
     * Creates a millisecond.
     *
     * @param time  the instant in time.
     * @param zone  the time zone.
     */
    public Millisecond(Date time, TimeZone zone) {

        this.second = new Second(time, zone);
        Calendar calendar = Calendar.getInstance(zone);
        calendar.setTime(time);
        this.millisecond = calendar.get(Calendar.MILLISECOND);

    }

    /**
     * Returns the second.
     *
     * @return The second.
     */
    public Second getSecond() {
        return this.second;
    }

    /**
     * Returns the millisecond.
     *
     * @return The millisecond.
     */
    public long getMillisecond() {
        return this.millisecond;
    }

    /**
     * Returns the millisecond preceding this one.
     *
     * @return The millisecond preceding this one.
     */
    public RegularTimePeriod previous() {

        RegularTimePeriod result = null;

        if (this.millisecond != FIRST_MILLISECOND_IN_SECOND) {
            result = new Millisecond(this.millisecond - 1, this.second);
        }
        else {
            Second previous = (Second) this.second.previous();
            if (previous != null) {
                result = new Millisecond(LAST_MILLISECOND_IN_SECOND, previous);
            }
        }
        return result;

    }

    /**
     * Returns the millisecond following this one.
     *
     * @return The millisecond following this one.
     */
    public RegularTimePeriod next() {

        RegularTimePeriod result = null;
        if (this.millisecond != LAST_MILLISECOND_IN_SECOND) {
            result = new Millisecond(this.millisecond + 1, this.second);
        }
        else {
            Second next = (Second) this.second.next();
            if (next != null) {
                result = new Millisecond(FIRST_MILLISECOND_IN_SECOND, next);
            }
        }
        return result;

    }

    /**
     * Returns a serial index number for the millisecond.
     *
     * @return The serial index number.
     */
    public long getSerialIndex() {
        return this.second.getSerialIndex() * 1000L + this.millisecond;
    }

    /**
     * Tests the equality of this object against an arbitrary Object.
     * <P>
     * This method will return true ONLY if the object is a Millisecond object
     * representing the same millisecond as this instance.
     *
     * @param obj  the object to compare
     *
     * @return <code>true</code> if milliseconds and seconds of this and object
     *      are the same.
     */
    public boolean equals(Object obj) {

        if (obj instanceof Millisecond) {
            Millisecond m = (Millisecond) obj;
            return ((this.millisecond == m.getMillisecond())
                    && (this.second.equals(m.getSecond())));
        }
        else {
            return false;
        }

    }

    /**
     * Returns a hash code for this object instance.  The approach described by 
     * Joshua Bloch in "Effective Java" has been used here:
     * <p>
     * <code>http://developer.java.sun.com/developer/Books/effectivejava
     * /Chapter3.pdf</code>
     * 
     * @return A hashcode.
     */
    public int hashCode() {
        int result = 17;
        result = 37 * result + this.millisecond;
        result = 37 * result + this.second.hashCode();
        return result;
    }

    /**
     * Returns an integer indicating the order of this Millisecond object
     * relative to the specified object:
     *
     * negative == before, zero == same, positive == after.
     *
     * @param obj  the object to compare
     *
     * @return negative == before, zero == same, positive == after.
     */
    public int compareTo(Object obj) {

        int result;
        long difference;

        // CASE 1 : Comparing to another Second object
        // -------------------------------------------
        if (obj instanceof Millisecond) {
            Millisecond ms = (Millisecond) obj;
            difference = getFirstMillisecond() - ms.getFirstMillisecond();
            if (difference > 0) {
                result = 1;
            }
            else {
                if (difference < 0) {
                    result = -1;
                }
                else {
                    result = 0;
                }
            }
        }

        // CASE 2 : Comparing to another TimePeriod object
        // -----------------------------------------------
        else if (obj instanceof RegularTimePeriod) {
            // more difficult case - evaluate later...
            result = 0;
        }

        // CASE 3 : Comparing to a non-TimePeriod object
        // ---------------------------------------------
        else {
            // consider time periods to be ordered after general objects
            result = 1;
        }

        return result;

    }

    /**
     * Returns the first millisecond of the time period.
     *
     * @return The first millisecond of the time period.
     */
    public long getFirstMillisecond() {
        return this.second.getFirstMillisecond() + this.millisecond;
    }

    /**
     * Returns the first millisecond of the time period.
     *
     * @param calendar  the calendar.
     *
     * @return The first millisecond of the time period.
     */
    public long getFirstMillisecond(Calendar calendar) {
        return this.second.getFirstMillisecond(calendar) + this.millisecond;
    }

    /**
     * Returns the last millisecond of the time period.
     *
     * @return The last millisecond of the time period.
     */
    public long getLastMillisecond() {
        return this.second.getFirstMillisecond() + this.millisecond;
    }

    /**
     * Returns the last millisecond of the time period.
     *
     * @param calendar  the calendar.
     *
     * @return The last millisecond of the time period.
     */
    public long getLastMillisecond(Calendar calendar) {
        return this.second.getFirstMillisecond(calendar) + this.millisecond;
    }

}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩亚洲欧美成人一区| 久久久亚洲欧洲日产国码αv| 久久精品久久99精品久久| 欧美国产一区二区在线观看 | 国产主播一区二区| 亚洲柠檬福利资源导航| 精品国产成人系列| 欧美在线观看视频在线| 粉嫩绯色av一区二区在线观看| 午夜私人影院久久久久| 国产精品色哟哟| 欧美变态口味重另类| 欧洲av在线精品| 91浏览器打开| 国产成人av一区| 蜜臀av一区二区| 亚洲成人中文在线| 亚洲日本va午夜在线电影| 欧美精品一区二区三区视频| 欧美日韩精品一区二区三区| 99riav一区二区三区| 国产电影一区在线| 久久精品二区亚洲w码| 午夜a成v人精品| 亚洲精品乱码久久久久| 国产精品久久久久桃色tv| 久久久精品免费观看| 日韩免费观看高清完整版在线观看| 色视频欧美一区二区三区| 成人激情校园春色| 国产激情视频一区二区在线观看| 爽好久久久欧美精品| 亚洲午夜视频在线| 亚洲午夜一区二区| 天天综合色天天综合色h| 亚洲成人精品一区二区| 亚洲成人黄色小说| 亚洲成人先锋电影| 亚洲成人在线观看视频| 午夜免费欧美电影| 五月天国产精品| 天天av天天翘天天综合网| 亚洲成人免费看| 丝袜亚洲另类欧美综合| 日韩一区精品视频| 日韩av中文在线观看| 青娱乐精品在线视频| 日韩高清一区二区| 久久精品久久99精品久久| 黄色日韩网站视频| 成人综合婷婷国产精品久久免费| 成人福利视频在线| 91久久人澡人人添人人爽欧美| 色国产综合视频| 欧美精三区欧美精三区| 91精品国产综合久久精品| 日韩欧美一二三| 国产欧美在线观看一区| 亚洲欧美经典视频| 婷婷丁香久久五月婷婷| 极品少妇xxxx偷拍精品少妇| 国产成人av电影| 91蝌蚪porny| 欧美乱熟臀69xxxxxx| 日韩女优制服丝袜电影| 日本一区二区成人| 亚洲一区二区三区中文字幕| 奇米影视在线99精品| 国产精品一区不卡| 色就色 综合激情| 欧美精三区欧美精三区| 国产欧美一区二区精品婷婷| 亚洲品质自拍视频| 免费看欧美美女黄的网站| 国产不卡视频一区| 欧美视频你懂的| 久久综合久久久久88| 亚洲欧美另类综合偷拍| 免费成人在线网站| av动漫一区二区| 91精品麻豆日日躁夜夜躁| 久久精品视频在线看| 亚洲综合无码一区二区| 精彩视频一区二区三区| 色综合久久综合网欧美综合网 | 欧美一区二区三区视频在线 | 成人免费毛片片v| 亚洲码国产岛国毛片在线| 日日骚欧美日韩| 国产宾馆实践打屁股91| 在线观看欧美黄色| 精品国产电影一区二区| 亚洲精品一二三| 国产一区在线观看视频| 欧美在线色视频| 亚洲一卡二卡三卡四卡| 婷婷中文字幕综合| 成人免费看的视频| 日韩无一区二区| 一区二区三区视频在线看| 国产呦精品一区二区三区网站| 一本久久a久久精品亚洲| 精品久久久久久久久久久院品网| 亚洲精品成人悠悠色影视| 国产精品一色哟哟哟| 欧美另类z0zxhd电影| 亚洲人成精品久久久久久| 国产黄色精品视频| 日韩欧美一区二区免费| 亚洲国产精品久久久男人的天堂| 丁香亚洲综合激情啪啪综合| 日韩欧美中文字幕精品| 亚洲成人资源在线| 色综合欧美在线| 中文字幕亚洲精品在线观看| 国内久久精品视频| 7777精品伊人久久久大香线蕉 | 蜜桃av一区二区三区| 色欧美88888久久久久久影院| 久久久99精品久久| 久久精品国产精品青草| 欧美精品亚洲一区二区在线播放| 亚洲视频一区二区免费在线观看 | 国产一级精品在线| 精品欧美久久久| 日韩和欧美的一区| 这里只有精品免费| 日韩中文字幕麻豆| 欧美精品久久久久久久久老牛影院| 亚洲日本电影在线| 色综合天天综合网国产成人综合天| 亚洲欧美在线高清| 国产精品资源站在线| 欧美成人a∨高清免费观看| 婷婷综合五月天| 欧美日韩国产综合视频在线观看| 尤物av一区二区| 色婷婷国产精品久久包臀| 亚洲精品中文字幕乱码三区| 99精品国产视频| 亚洲同性gay激情无套| 99re这里都是精品| 亚洲免费av网站| 欧洲另类一二三四区| 亚洲午夜在线电影| 欧美日韩1234| 欧美aaaaaa午夜精品| 欧美videos大乳护士334| 韩国精品主播一区二区在线观看 | 国产精品资源在线观看| 亚洲国产精品成人久久综合一区| 国产成人亚洲综合a∨猫咪| 国产欧美综合色| 91麻豆成人久久精品二区三区| 亚洲女厕所小便bbb| 欧美在线观看18| 日韩电影在线免费看| 日韩免费观看2025年上映的电影| 极品少妇xxxx偷拍精品少妇| 中文字幕电影一区| 一本久道久久综合中文字幕| 夜夜嗨av一区二区三区四季av | 国产精品热久久久久夜色精品三区 | 一本大道久久a久久精品综合| 国产精品乱人伦中文| 色欧美片视频在线观看在线视频| 一区二区三区小说| 欧美色综合网站| 日本亚洲视频在线| 久久综合成人精品亚洲另类欧美 | 久久只精品国产| 国产九九视频一区二区三区| 国产亚洲欧美一区在线观看| 不卡一区在线观看| 亚洲精品老司机| 欧美日韩成人一区| 麻豆精品国产传媒mv男同 | 中文字幕av资源一区| 一本色道亚洲精品aⅴ| 亚洲成人av一区| 日韩一卡二卡三卡| 国产精品一二三| 亚洲欧美日韩久久| 欧美一区二区成人6969| 激情都市一区二区| 综合久久久久久久| 欧美人伦禁忌dvd放荡欲情| 久久国产精品一区二区| 国产日韩精品一区| 91久久一区二区| 国产在线精品免费av| 亚洲午夜一区二区三区| 国产欧美日韩在线看| 色诱亚洲精品久久久久久| 在线观看日韩电影| 国产成人日日夜夜| 午夜视黄欧洲亚洲| 亚洲天堂精品视频| 久久午夜色播影院免费高清| 精品视频在线视频|