Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:

Barrons Publishing Dictionary of Computer and Internet Terms 10th

.pdf
Скачиваний:
158
Добавлен:
10.08.2013
Размер:
9.33 Mб
Скачать

Java

266

/* File showball.java */

/* Displays red or blue circles when user clicks mouse */

import java.awt.*; import java.applet.*;

public class showball extends Applet { Graphics g; int rc,gc,bc; ball ballobject;

public void init() { setLayout(null);

Button bluebutton = new Button(“Blue”); add(bluebutton); bluebutton.reshape(0,0,100,20);

Button redbutton = new Button(“Red”); add(redbutton); redbutton.reshape(110,0,100,20); ballobject = new ball();

}

public boolean action(Event e, Object o) { if (Red.equals(o))

{rc=255; gc=0; bc=0;} else if (Blue.equals(o))

{rc=0; gc=0; bc=255;} return false;

}

public boolean mouseDown(Event e, int x, int y) { ballobject.xc = x; ballobject.yc = y; ballobject.redcode = rc; ballobject.greencode = gc; ballobject.bluecode = bc;

repaint();

return false;

}

 

public void paint(Graphics g) { ballobject.drawball(g);

}

}

/* File ball.java */

import java.awt.*; import java.applet.*;

public class ball {

int xc,yc,redcode,greencode,bluecode; public void drawball(Graphics g2) {

Color rgbcolor = new Color (redcode, greencode, bluecode);

g2.setColor(rgbcolor);

g2.fillArc(xc,yc,25,25,0,360);

/* fillArc is included with the class applet*/

}

}

FIGURE 144. Java program (comprising 2 files)

267

JCL

JavaScript a language that allows a web page to include commands to be executed by the web browser. For example, you may wish your web page to have dialog boxes that appear when the user clicks on certain places. Or, if your web page will send information back to the server, you can use JavaScript to catch some common data entry errors before it is sent. This will save work for the server.

JavaScript was originally developed by Netscape. The name comes from the fact that JavaScript shares some syntax and object-oriented features with Java, but they are actually quite different languages. JavaScript commands are interpreted by the web browser (see INTERPRETER), rather than being compiled into bytecode as Java programs are. JavaScript is easier to learn than Java, particularly if you already know HTML, but, unlike Java, it does not have the features of a complete programming language.

Figure 145 is an example of how JavaScript can be used together with an HTML form to receive information from a customer. In this example, the user enters the item number, price, and quantity for two different items into the form. Two different JavaScript functions are defined. The function addup is called by the event handler onChange that is located in the HTML code for the form. Whenever one of these fields is changed, JavaScript checks for negative values and then multiplies the price times the quantity and adds up the total dollar amount.

Figure 146 shows the appearance of the screen when this web page is loaded.

For another example of programming in JavaScript, see ROLLOVER.

JBOD (just a bunch of disks) DISK SHARING in which the disks are treated separately, not organized into a RAID system. See RAID.

JCL (Job Control Language) the command language used in batch jobs to tell a computer what to do. (See BATCH PROCESSING.) The acronym JCL usually refers to the job control language used on large IBM computers, but sometimes designates very different languages used for the same purpose on other computers.

The following is an example of JCL for an IBM 360; the language is the same for all IBM mainframe computers running operating systems derived from OS/360, such as OS/VS2, and MVS:

//JONES JOB 123456,TIME=5 // EXEC PLIXCG

//PLI.SYSIN DD DSN=JONES.SAMPL.PLI,DISP=SHR //GO.SYSIN DD *

1 2 3 4 /*

//

The first statement is the JOB card, which gives the job a name, specifies the user’s account number, and establishes a CPU time limit of 5 minutes for the whole job. The EXEC PLIXCG statement calls up the procedure to compile and execute a PL/1 program; its operation happens to consist of two steps, PLI (compile) and GO (execute).

JCL

268

<HTML>

 

<HEAD><TITLE>

JavaScript Example</TITLE>

<SCRIPT LANGUAGE=JavaScript>

function multiply(a,b) {

if ((a>=0)&(b>=0)) {return a*b;}

else {window.alert(Value can’t be negative); return invalid;}

}

function addup() {

var totalamount=0; var amount=0; for (i=1; i<=2; i++) {

amount= multiply

(document.orderform.elements[i*4-2].value, document.orderform.elements[i*4-1].value); document.orderform.elements[i*4].value=amount;

totalamount+=amount;

}

document.orderform.total.value=totalamount;

}

</SCRIPT>

</HEAD>

<BODY>

<H1> Order Form Example </H1>

<FORM NAME=orderform>

<ACTION mailto:youraddress@xyz.com>

Your Name: <INPUT TYPE= textNAME=customernameSIZE=20><br>

Item Number:<INPUT TYPE=textNAME=item1SIZE=5> Price:<INPUT TYPE=textNAME=price1

SIZE=5 onChange=addup();> Quantity:<INPUT TYPE=textNAME=quant1

SIZE=5 onChange=addup();>

Value: $<INPUT TYPE=textNAME=value1SIZE=8 onChange=addup();><BR>

Item Number:<INPUT TYPE=textNAME=item2SIZE=5>

Price:<INPUT TYPE=textNAME=price2

SIZE=5 onChange=addup();>

Quantity:<INPUT TYPE=textNAME=quant2

SIZE=5 onChange=addup();>

Value: $<INPUT TYPE=textNAME=value2

SIZE=8 onChange=addup();><BR>

Total Value: $<INPUT TYPE=textNAME=total

SIZE=8 onChange=addup();><BR>

<INPUT TYPE=SUBMITNAME=submitVALUE=E-Mail your orderSIZE=40>

</FORM>

</BODY>

</HTML>

FIGURE 145. JavaScript example

269

joystick

FIGURE 146. JavaScript in action

The DD (data definition) statements define files. SYSIN (standard system input) for the PLI step is defined as a cataloged disk data set named JONES.SAMPL.PLI; SYSIN for the GO step is given in the job itself, beginning after DD * and ending with /*. The // card marks the end of the job.

JDK (Java Development Kit) a system provided free by Sun Microsystems that can be used to write Java programs. It comes with a Java compiler, standard class library, and an applet viewer.

jewel case a rigid clear-plastic case that protects compact discs (CDs). The paper insert for the face of a jewel case is 120 mm (4.7 inches) square.

JIT compiler (just-in-time compiler) a compiler that converts intermediate code into native machine language the first time it is encountered; this allows subsequent execution of that code to occur faster.

job see BATCH PROCESSING.

join see RELATIONAL DATABASE.

Joliet file system an extension to the ISO 9660 format for recording CD-ROMs, created by Microsoft in order to support long filenames and long directory names. It is the usual format for CD-ROMs to be used under Windows 95 and later. See also ROCK RIDGE.

joo LEETSPEAK for “you.”

joule a unit for measuring amounts of energy. 1 joule equals 1 kilogrammeter2/second2. One watt is equivalent to one joule per second. See

VOLT; WATT; WATT-HOUR.

joystick a computer input device especially helpful when playing computer games. The joystick consists of a handle that can be pointed in different directions. Because the computer can sense in which direction the joystick is pointed, the joystick can be used to control the movements of objects displayed on the computer screen.

JPEG

270

JPEG (Joint Photographic Experts Group) a file format for storing bitmap images, including lossy compression (i.e., a file can be compressed to a very small size if some blurring of detail is tolerable). JPEG file format is often used for high-quality photographic images. Filenames usually end in .jpeg or .jpg.

JScript a version of JAVASCRIPT developed by Microsoft.

jukebox a device for automatically selecting disks (usually CD-ROMs) from a library and inserting the desired one into the disk drive.

Julian calendar the calendar introduced in 46 B.C. by Julius Caesar, with a leap year every four years. See GREGORIAN CALENDAR; LEAP YEAR.

Julian date

1.the number of days elapsed since January 1, 4713 B.C., counting that date as day 1. The Julian date is now used primarily by astronomers. It is unrelated to the Julian calendar. The Julian date was introduced in 1582 A.D. by J. J. Scaliger, who named it for his father Julius. Its original purpose was to convert dates between various ancient calendars without using negative numbers. The Julian date of January 1, 2000 is 2,451,544.

2.more loosely, any date expressed as a day count rather than as year, month, and day.

jump list a WEB PAGE consisting mostly of links to other web pages. See

HTML; INTERNET; LINK (definition 3); WORLD WIDE WEB.

JumpDrive Lexar’s trademark for a brand of USB FLASH DRIVE. See Figure 285, page 507.

jumper a removable electrical connector that joins two pins on a circuit board. Many of the internal settings in computers are made by moving or removing jumpers.

junction the part of a diode or transistor where two opposite types of semiconductor material meet. See DIODE; TRANSISTOR.

junk e-mail unsolicited electronic mail, usually containing advertisements.

See SPAM.

junk fax an unsolicited advertisement transmitted by fax. In 1991, sending junk faxes was made illegal in the United States because it imposes an expense on the recipient (who has to pay for the paper) and ties up machines that are needed for more important messages. This law (47 USC 227) was overturned by a district court in 2002 (Missouri v. American Blast Fax), but the law was reinstated by an appeals court in 2003.

junkware unwanted demonstration software added to a new computer by the seller.

271

Jython

justification the insertion of extra space between words in lines of type so that the left and right margins are even and smooth. Most of the type in this book is justified.

Most word processors and desktop publishing programs can automatically do the computations necessary to justify type. Problems generally arise only when the column width is too narrow, or too large a HOT ZONE has been specified. Then you will get rivers of white space running down the column (not too attractive). To cure this, make sure hyphenation is enabled, shrink the hot zone, go to a smaller type size, or increase the column width. See RIVER.

JVM (Java Virtual Machine) software that executes Java bytecode. A program written in Java is first compiled into class files, written in bytecode. To execute these files, the computer needs to use the JVM to interpret the code. The JVM is built into web browsers that are capable of executing Java applets. The bytecode is the same for all platforms, but the JVM will be different on different platforms because it needs to execute using the native code of the machine it is running on.

Jython an implementation of PYTHON based on JAVA. See www.jython.org.

X WINDOW SYSTEM GNOME.

k, K

272

K

k, K abbreviation for KILOBYTE (or, less commonly, kilohm or other metric units). By convention, a capital K stands for a factor of 1,024, and a lowercase k stands for a factor of 1000, as in the metric system (kilograms, kilometers, etc.). See also BYTE; MEGABYTE; MEMORY.

K56flex a standard formerly used by Rockwell and other modem manufacturers for transmitting data on telephone lines at speeds up to 56,600 bits per second.

K6 chip microprocessor introduced by AMD in 1997 as a competitor to the Intel Pentium.

kana the Japanese phonetic writing system. There are two styles, hiragana and katakana. Kana contrasts with kanji, the Chinese-derived symbols for whole words. Written Japanese uses a mixture of kana and kanji.

kanji see KANA.

katakana see KANA.

KB abbreviation for KILOBYTE.

kBps kiloBytes per second. See also BAUD; KILOBYTE.

kbps kilobits per second. See BIT.

KDE (KDesktop Environment) a widely used graphical desktop environment for Linux and UNIX systems, based on the and originated by Matthias Ettrich in 1996. Compare

Kerberos an authentication protocol that allows users and computers to identify each other without risk of impersonation and to communicate securely by encrypting their data. A Kerberos system uses a central authentication server to issue tickets, which are temporary authorizations to communicate. Each ticket is valid only for a specific user and for a limited length of time. Thus, an intercepted or stolen ticket is of little use. Because of the encryption used, forged tickets are virtually impossible to produce.

Kerberos was developed at the Massachusetts Institute of Technology, which distributes an implementation of it free of charge (web.mit.edu/kerberos/www). Kerberos has many commercial implementations. See PROTOCOL. In Greek mythology, Kerberos (in Latin, Cerberus) is the dog that guards the gate of Hades.

Kermit a protocol for transferring files from one computer to another by modem without going through the Internet. Kermit is also the name of a program (distributed free by Columbia University) that implements this protocol.

273

keyboarding

Kermit makes an exact copy of the original file even when transmitting over a noisy line. All data packets are error-checked, and erroneous packets are retransmitted. See PROTOCOL.

kernel the central part of an OPERATING SYSTEM. In many operating systems, only the kernel can access hardware directly.

Usage note: For obscure reasons this term is often spelled kernal. This may be nothing more than a typing error that appeared in an influential manual and caught on.

kerning adjustment of the amount of space between certain combinations of letters in proportional-pitch type. If the combination “To” is typeset with the same letter spacing as “Th,” the letters seem to be too widely spaced. “To” looks better if the top of the “T” is allowed to overhang the “o” slightly. See Figure 147. Compare TRACKING.

To Without kerning

To With exaggerated kerning

Figure 147. Kerning

key

1.a button on a computer keyboard.

2.the item by which a data file is sorted or searched. For instance, if a file of names and addresses is sorted by zip codes, then the zip code is the key.

3.the password or other secret information needed to decode an encrypted message. See ENCRYPTION.

keyboard the primary computer input device for alphanumeric data. There are many different types of keyboard layouts; for the most part the alphabet and numbers are consistently placed, but there is considerable variation in the placement of the auxiliary characters, editing keys, and function keys. Most keyboards have a numeric keypad (for typing digits) at the right; if you use a mouse a lot, but don’t type many numbers, you may prefer a narrower keyboard that omits the keypad and lets you put your mouse closer to where you sit. Some keyboards have a mouselike pointing device built in; these are generally fine for menu selection but not precise enough for drawing.

When buying a new computer, be sure to evaluate the keyboard carefully. A keyboard that feels “dead” can be tiring to use. Practice typing on several different models to find one that feels good to you. Spending a few extra dollars for a good keyboard can be a wise investment; after all, it is the part of your computer that you are in contact with constantly.

keyboard shortcut see SHORTCUT.

keyboarding entering data through the keyboard; typing.

keying

274

keying

1.typing; inputting information into the computer by means of the keyboard.

2.the process of digitally combining video images by using a subtractive background. See CHROMA-KEYING.

keylogging see KEYSTROKE LOGGING.

keystroke logging the act of recording the keys that a person presses as he or she uses a computer. Keystroke logging is often done surreptitiously by malicious SPYWARE in an attempt to capture passwords.

keyword

1.a word that has a special meaning in a particular programming language. For example, for is a keyword in C, and BEGIN is a keyword in Pascal.

2.words or phrases that, when included in the META tag of an HTML document, help SEARCH ENGINEs catalog the contents of that web page.

kibi- proposed metric prefix meaning ×1024 (210), the binary counterpart of kilo-. See METRIC PREFIXES.

kibibyte 1024 bytes.

kill file a list of people whose incoming e-mail messages or newsgroup postings are automatically deleted or hidden from view. Many mail and news reading programs allow you to set up a kill file so that obnoxious messages from known senders can be avoided. It is hard to avoid SPAM this way because spammers constantly change their names. Compare

BLACKLIST; IGNORE LIST.

killer app (slang) a software application that becomes so desirable that it is the reason people purchase a computer, computer peripheral, or operating system. For example, Visicalc was a killer app for the Apple II, and Lotus 1-2-3 was a killer app for the original IBM PC. Some operating systems, such as OS/2, have failed to become popular because of the lack of a killer app.

kilo- metric prefix meaning ×1000 (103) or, in rating computer memories and disks, ×1024. Kilo- is derived from the Greek word for “thousand.”

See METRIC PREFIXES.

kilobyte a unit of computer memory capacity equal to 1024 characters. The number 1024 is significant because 210 = 1024.

By convention, a capital K stands for a factor of 1024, and a lowercase k stands for a factor of 1000, as in the metric system (kilograms, kilometers, etc.). See also BYTE; MEGABYTE; MEMORY.

kilowatt-hour a unit of electrical energy consumption equal to 1000 watthours. See WATT-HOUR.

275

Kylix

Kindle a portable reading device introduced by Amazon in 2007, including a screen with an appearance similar to paper. Books and periodicals can be downloaded to the Kindle wirelessly.

kiosk a small stand containing a computer that people can walk up to and use to retrieve information. Kiosks often display current information about local events. They are used in museums, airports, and other public places.

kluge (pronounced “klooge”) an improvised, jury-rigged, and poorly thought-out solution to a problem, usually intended only for temporary use. The word kluge may be derived from German klug, which means “clever.” In Britain it is sometimes spelled kludge and pronounced to rhyme with “sludge.”

knife (drawing program) a tool that cuts an object into pieces, defining a new outline along the cut edge and thus preserving the fill attributes of the original object.

knockout an area where an underlying color has been cut out so that the overprinting color can remain pure. Some DESKTOP PUBLISHING software automatically creates knockouts and TRAPs when preparing files for duplication on a printing press (see PREPRESS).

(Knockout applies to mass production printing with a printing press, not to inkjet or laser printers attached directly to computers.)

knowledge base a collection of knowledge that is used as the basis for solving problems or making recommendations. See EXPERT SYSTEM.

Koch snowflake see FRACTAL.

KVM switch (Keyboard-Video-Mouse switch) a device that allows several computers to share a single keyboard, screen, and mouse. By pressing a button on the KVM switch or by typing special keystrokes, the user can connect the keyboard, screen, and mouse to any of the computers.

Kylix a development environment for C++ and Delphi programming under Linux, produced by Borland International. See DELPHI.

Соседние файлы в предмете Английский язык