⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 main.java

📁 httptunnel.jar httptunnel java 源码
💻 JAVA
字号:
/*
 * Copyright (C) 2001 Ciaran Treanor <ciaran@codeloop.com>
 *
 * Distributable under GPL license.
 * See terms of license at gnu.org.
 *
 * $Id: Main.java,v 1.1 2004/07/22 09:34:10 saxon64 Exp $
 */
package net.jumperz.ext.org.jrobin.core.jrrd;

import java.io.IOException;

/**
 * Show some of the things jRRD can do.
 *
 * @author <a href="mailto:ciaran@codeloop.com">Ciaran Treanor</a>
 * @version $Revision: 1.1 $
 */
public class Main {

	public Main(String rrdFile) {

		RRDatabase rrd = null;
		DataChunk chunk = null;

		try {
			rrd = new RRDatabase(rrdFile);
			chunk = rrd.getData(ConsolidationFunctionType.AVERAGE);
		} catch (Exception e) {
			e.printStackTrace();

			return;
		}

		rrd.toXml(System.out);        // Dump the database as XML.
		rrd.printInfo(System.out);    // Dump the database header information.
		System.out.println(rrd);      // Dump a summary of the contents of the database.
		System.out.println(chunk);    // Dump the chunk.

		try {
			rrd.close();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	static void usage(int status) {
		System.err.println("Usage: " + Main.class.getName() + " rrdfile");
		System.exit(status);
	}

	public static void main(String[] args) {
		if (args.length != 1) {
			usage(1);
		}
		new Main(args[0]);
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -