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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? coursecatalog.java

?? 一個美國教授寫得很好的java學(xué)生管理系統(tǒng)
?? JAVA
字號:
// CourseCatalog.java - Chapter 16 version.

// Copyright 2000 by Jacquie Barker - all rights reserved.

// An IMPLEMENTATION class.
package Courses;

import java.util.*;
import java.io.*;
import DataInterface.CollectionWrapper;

public class CourseCatalog extends CollectionWrapper {
	//------------
	// Attributes.
	//------------

	// This Hashtable stores Course object references, using
	// the (String) course no. of the Course as the key.

	private Hashtable courses;

	//----------------
	// Constructor(s).
	//----------------

	public CourseCatalog() {
		// Instantiate a new Hashtable.

		courses = new Hashtable();
	}

	//-----------------
	// Get/set methods.
	//-----------------


	//-----------------------------
	// Miscellaneous other methods.
	//-----------------------------

	// Used for testing purposes.
	
	public void display() {
		System.out.println("Course Catalog:");
		System.out.println("");

		// Step through the Hashtable and display all entries.

		Enumeration e = courses.elements();

		while (e.hasMoreElements()) {
			Course c = (Course) e.nextElement();
			c.display();
			System.out.println("");
		}
	}

	public void addCourse(Course c) {
		// We use the course no. as the key.

		String key = c.getCourseNo();
		courses.put(key, c);
	}

	public void parseData(String line) {
		// We're going to parse tab-delimited records into
		// three attributes -- courseNo, courseName, and credits --
		// and then call the Course constructor to fabricate a new
		// course.

		// First, make a copy of the record.

		String restOfLine = line;

		// Use the indexOf() method to search for the first
		// occurrence of a tab character.  The variable "index"
		// will contain an integer pointing to the character
		// position in the record (starting with 0 for the first
		// position) of where the first tab character sits.

		int index = restOfLine.indexOf("\t");

		// We subdivide the line into two segments:  the portion
		// which precedes the tab ...

		String courseNo = restOfLine.substring(0, index);

		// ... and the portion which follows it (note that by
		// adding 1 to the value of index we have jumped past
		// the first tab character).

		restOfLine = restOfLine.substring(index+1);

		// We now search the REST of the line for the NEXT
		// tab character, and once again subdivide the
		// remainder of the record into two segments.

		index = restOfLine.indexOf("\t");
		String courseName = restOfLine.substring(0, index);
		String creditValue = restOfLine.substring(index+1);

		// We have to convert the last value into a number,
		// using a static method on the Double class to do so.

		double credits = Double.parseDouble(creditValue);

		// Finally, we call the Course constructor to create
		// an appropriate Course object, and store it in our
		// collection.

		Course c = new Course(courseNo, courseName, credits);
		addCourse(c);
	}

	public Course findCourse(String courseNo) {
		return (Course) courses.get(courseNo);
	}

	// We must read a second file defining the prerequisites, in
	// order to "hook" Course objects together.
	// This next version is used when reading in prerequisites.

	public void parseData2(String line) {
		// We're going to parse tab-delimited records into
		// two values, representing the courseNo "A" of 
		// a course that serves as a prerequisite for 
		// courseNo "B".

		// First, make a copy of the record.

		String restOfLine = line;
		int index = restOfLine.indexOf("\t");
		String courseNoA = restOfLine.substring(0, index);
		String courseNoB = restOfLine.substring(index+1);

		// Look these two courses up in the CourseCatalog.

		Course a = findCourse(courseNoA); 
		Course b = findCourse(courseNoB); 
		if (a != null && b != null) b.addPrerequisite(a);
	}

	// Test scaffold.
	public static void main(String[] args) {
		// We instantiate a CourseCatalog object ...

		CourseCatalog cc = new CourseCatalog();

		// ... cause it to read both the CourseCatalog.dat and
		// Prerequisites.dat files, thereby testing both
		// the parseData() and parseData2() methods internally
		// to the initializeObjects() method ...

		cc.initializeObjects("CourseCatalog.dat", true);
		cc.initializeObjects("Prerequisites.dat", false);

		// ... and use its display() method to demonstrate the
		// results!

		cc.display();
	}
}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产经典欧美精品| 91精品蜜臀在线一区尤物| 在线区一区二视频| 精品99999| 偷窥少妇高潮呻吟av久久免费| 国产成a人亚洲| 欧美一级高清片在线观看| 一区二区三区在线观看欧美| 国内精品免费在线观看| 欧美日韩免费高清一区色橹橹| 国产精品女人毛片| 精品一区二区成人精品| 欧美一区二区三区四区高清| 亚洲免费视频中文字幕| 91麻豆福利精品推荐| 精品国产污污免费网站入口| 三级一区在线视频先锋| 91福利在线导航| 亚洲欧美日韩久久| 99精品1区2区| 日韩理论电影院| 成人少妇影院yyyy| 欧美国产激情一区二区三区蜜月| 免费成人美女在线观看.| 5月丁香婷婷综合| 丝瓜av网站精品一区二区| 精品视频123区在线观看| 一区二区三区在线播| 一本大道久久a久久精品综合| 国产精品视频麻豆| 波多野结衣一区二区三区| 国产精品丝袜久久久久久app| 国产成人a级片| 中文字幕欧美国产| 99久久精品免费看国产| 亚洲视频在线一区| 91亚洲资源网| 亚洲小少妇裸体bbw| 欧美色区777第一页| 午夜精品福利一区二区三区av| 欧美日韩高清一区二区| 五月天激情综合网| 日韩一区二区免费高清| 韩国成人在线视频| 国产精品午夜电影| 色综合久久中文字幕综合网| 亚洲在线免费播放| 337p亚洲精品色噜噜| 美国十次了思思久久精品导航| 日韩美女视频在线| 福利视频网站一区二区三区| 亚洲天堂网中文字| 欧美酷刑日本凌虐凌虐| 久久99国产精品免费网站| 国产欧美精品一区| 日本韩国欧美三级| 日韩中文字幕av电影| 久久精品一二三| 色综合久久中文综合久久97| 天涯成人国产亚洲精品一区av| 日韩一区二区三区视频在线观看| 国产乱淫av一区二区三区| **欧美大码日韩| 91麻豆精品国产91久久久| 国产一区二区三区不卡在线观看| 国产精品另类一区| 91精品国产综合久久婷婷香蕉| 国产在线不卡一卡二卡三卡四卡| 亚洲人妖av一区二区| 欧美一区二区三区成人| eeuss影院一区二区三区| 日韩精品色哟哟| 中文字幕在线一区免费| 69堂成人精品免费视频| 99久久伊人精品| 免费人成黄页网站在线一区二区| 中文字幕久久午夜不卡| 这里是久久伊人| 色综合中文字幕| 国产成人自拍高清视频在线免费播放| 亚洲香蕉伊在人在线观| 国产片一区二区| 日韩一区二区在线免费观看| 色婷婷激情一区二区三区| 国产真实乱偷精品视频免| 亚洲丶国产丶欧美一区二区三区| 国产亚洲欧美在线| 日韩免费一区二区| 欧美午夜在线观看| 北条麻妃国产九九精品视频| 久久99久久久久| 午夜成人免费电影| 亚洲精品乱码久久久久久久久| 久久精品亚洲精品国产欧美kt∨ | 欧美亚洲日本一区| 国产成人av一区二区三区在线| 三级在线观看一区二区| 夜夜精品视频一区二区 | 国产a级毛片一区| 麻豆精品蜜桃视频网站| 亚洲国产sm捆绑调教视频 | 337p日本欧洲亚洲大胆精品| 欧美日韩成人激情| 欧美在线|欧美| 91福利精品第一导航| 成人免费视频视频| 成人一区二区三区| 国产成人av在线影院| 国产成人亚洲综合a∨婷婷| 国内精品在线播放| 国产伦理精品不卡| 久久99精品久久久久| 老司机午夜精品| 久久国产精品无码网站| 精品一区二区三区的国产在线播放| 日韩激情一区二区| 蜜臀久久99精品久久久久久9| 老汉av免费一区二区三区| 偷窥少妇高潮呻吟av久久免费| 亚洲444eee在线观看| 三级久久三级久久| 久久se这里有精品| 国产成人精品aa毛片| 成人av在线网站| 99re这里都是精品| 欧美日韩综合色| 91精品蜜臀在线一区尤物| 欧美mv和日韩mv国产网站| 久久久久久久免费视频了| 久久久久久日产精品| 国产精品久久久久四虎| 亚洲精品伦理在线| 日产欧产美韩系列久久99| 精品无码三级在线观看视频| 懂色av中文一区二区三区| 不卡电影免费在线播放一区| 91福利社在线观看| 欧美成人精品高清在线播放| 中文字幕av一区二区三区高 | 精品福利在线导航| 国产精品污www在线观看| 一区二区三区四区乱视频| 日韩国产欧美在线视频| 国产精品系列在线播放| 色狠狠一区二区三区香蕉| 欧美一级片在线观看| 国产女同互慰高潮91漫画| 一区二区三区.www| 国产美女一区二区三区| 色综合久久综合| 亚洲精品一区二区三区香蕉 | 一本色道久久综合亚洲aⅴ蜜桃| 欧美三级视频在线| 久久精品这里都是精品| 亚洲国产一区二区三区| 国产成人av在线影院| 欧美日韩国产在线播放网站| 国产三级精品三级| 性久久久久久久久久久久| 成人永久看片免费视频天堂| 91麻豆精品国产91久久久资源速度| 国产精品伦一区二区三级视频| 欧美aaa在线| 色综合咪咪久久| 日本一区二区免费在线观看视频| 午夜日韩在线电影| 99久久综合国产精品| 精品久久国产老人久久综合| 亚洲国产美国国产综合一区二区| 国产不卡视频在线观看| 日韩欧美一区二区三区在线| 亚洲精品videosex极品| 国产精品白丝jk黑袜喷水| 在线综合+亚洲+欧美中文字幕| 1024成人网色www| 国产福利电影一区二区三区| 91麻豆精品国产91久久久久久久久| 亚洲精品中文字幕在线观看| 国产电影一区在线| 日韩精品一区二区三区在线播放| 亚洲一区二区三区在线| av不卡在线播放| 亚洲国产精品成人综合色在线婷婷| 日韩av一级片| 欧美人与z0zoxxxx视频| 一区二区三区四区激情 | 欧美亚日韩国产aⅴ精品中极品| 国产精品污污网站在线观看| 国产一区二区三区| 26uuu国产日韩综合| 久久99久久精品| 精品久久久久久久一区二区蜜臀| 日韩激情av在线| 91精品欧美福利在线观看| 日欧美一区二区| 欧美一区二区日韩一区二区| 日韩国产欧美在线播放| 欧美一区二区在线观看| 日韩高清一区在线| 日韩欧美久久久|