JRE 8 rt.jar - com.* Package Source Code

JRE 8 rt.jar is the JAR file for JRE 8 RT (Runtime) libraries. JRE (Java Runtime) 8 is the runtime environment included in JDK 8. JRE 8 rt.jar libraries are divided into 6 packages:

com.* - Internal Oracle and Sun Microsystems libraries
java.* - Standard Java API libraries.
javax.* - Extended Java API libraries.
jdk.* -  JDK supporting libraries.
org.* - Third party libraries.
sun.* - Old libraries developed by Sun Microsystems.

JAR File Information:

Directory of C:\fyicenter\jdk-1.8.0_191\jre\lib
      63,596,151 rt.jar

Here is the list of Java classes of the com.* package in JRE 1.8.0_191 rt.jar. Java source codes are also provided.

✍: FYIcenter

com/sun/jmx/snmp/Timestamp.java

/*
 *
 * Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
 * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 */
// Copyright (c) 1995-96 by Cisco Systems, Inc.

package com.sun.jmx.snmp;

// java imports
//
import java.util.Date;

/**
 * This class is used by the {@link com.sun.jmx.snmp.SnmpVarBindList SnmpVarBindList} object.
 * An <CODE>SnmpVarBindList</CODE> time stamp object represents the time stamp when the list was updated
 * with the response variables.
 * <p><b>This API is a Sun Microsystems internal API  and is subject
 * to change without notice.</b></p>
 */

public class Timestamp implements java.io.Serializable {
    private static final long serialVersionUID = -242456119149401823L;

    // PRIVATE VARIABLES
    //------------------

    /**
     * The time (in hundreds of a second) since the network management portion of the system
     * was last re-initialized.
     */
    private long sysUpTime ;

    /**
     * A <CODE>long</CODE> representing the current date.
     */
    private long crtime ;

    /**
     * The <CODE>SnmpTimeticks</CODE> object corresponding to the <CODE>TimeStamp</CODE> object.
     */
    private SnmpTimeticks uptimeCache = null ;


    // CONSTRUCTORS
    //-------------

    /**
     * The default constructor. <CODE>Sysuptime</CODE> is 0.
     * This simply indicates when this object was created.
     */
    public Timestamp() {
        crtime = System.currentTimeMillis() ;
    }

    /**
     * Creates a <CODE>TimeStamp</CODE> object using the user parameters.
     * @param uptime The time (in hundredths of a second) since the
     * network management portion of the system was last re-initialized.
     * @param when The current time.
     */
    public Timestamp(long uptime, long when) {
        sysUpTime = uptime ;
        crtime = when ;
    }

    /**
     * Creates a <CODE>TimeStamp</CODE> object using the user parameters.
     * @param uptime The time (in hundredths of a second) since the
     * network management portion of the system was last re-initialized.
     */
    public Timestamp(long uptime) {
        sysUpTime = uptime ;
        crtime = System.currentTimeMillis() ;
    }


    // GETTER/SETTER
    //--------------

    /**
     * Gets the <CODE>SnmpTimeticks</CODE> object corresponding to the <CODE>TimeStamp</CODE> object.
     * @return The <CODE>SnmpTimeticks</CODE> object.
     */
    final public synchronized SnmpTimeticks getTimeTicks() {
        if (uptimeCache == null)
            uptimeCache = new SnmpTimeticks((int)sysUpTime) ;
        return uptimeCache ;
    }

    /**
     * Gets the time (in hundredths of a second) since the network management portion of the system
     * was last re-initialized.
     * @return The <CODE>sysUpTime</CODE>.
     */
    final public long getSysUpTime() {
        return sysUpTime ;
    }

    /**
     * Gets the current date.
     * @return A <CODE>Date</CODE> object representing the current date.
     */
    final public synchronized Date getDate() {
        return new Date(crtime) ;
    }

    /**
     * Gets the current date.
     * @return A <CODE>long</CODE> representing the current date.
     */
    final public long getDateTime() {
        return crtime ;
    }

    /**
     * Returns a <CODE>String</CODE> representation of the <CODE>TimeStamp</CODE> object.
     * @return A <CODE>String</CODE> representation of the <CODE>TimeStamp</CODE> object.
     */
    final public String toString() {
        StringBuffer buf = new StringBuffer() ;
        buf.append("{SysUpTime = " + SnmpTimeticks.printTimeTicks(sysUpTime)) ;
        buf.append("} {Timestamp = " + getDate().toString() + "}") ;
        return buf.toString() ;
    }
}

com/sun/jmx/snmp/Timestamp.java

 

Or download all of them as a single archive file:

File name: jre-rt-com-1.8.0_191-src.zip
File size: 8099783 bytes
Release date: 2018-10-28
Download 

 

Backup JDK 8 Installation Directory

JRE 8 rt.jar - org.* Package Source Code

Download and Use JDK 8

⇑⇑ FAQ for JDK (Java Development Kit)

2023-02-07, 250638👍, 3💬