Java Reference
In-Depth Information
match any primitive numeric data type in Java. The more bytes there are in each address,
the more addresses there are available and the more devices that can be connected to
the network simultaneously.
Addresses are assigned differently on different kinds of networks. Ethernet addresses
are attached to the physical Ethernet hardware. Manufacturers of Ethernet hardware
use preassigned manufacturer codes to make sure there are no conflicts between the
addresses in their hardware and the addresses of other manufacturers' hardware. Each
manufacturer is responsible for making sure it doesn't ship two Ethernet cards with the
same address. Internet addresses are normally assigned to a computer by the organi‐
zation that is responsible for it. However, the addresses that an organization is allowed
to choose for its computers are assigned by the organization's Internet service provider
(ISP). ISPs get their IP addresses from one of four regional Internet registries (the reg‐
istry for North America is ARIN , the American Registry for Internet Numbers), which
are in turn assigned IP addresses by the Internet Corporation for Assigned Names and
Numbers ( ICANN ).
On some kinds of networks, nodes also have text names that help human beings identify
them such as “www.elharo.com” or “Beth Harold's Computer.” At a set moment in time,
a particular name normally refers to exactly one address. However, names are not locked
to addresses. Names can change while addresses stay the same; likewise, addresses can
change while the names stay the same. One address can have several names and one
name can refer to several different addresses.
All modern computer networks are packet-switched networks: data traveling on the
network is broken into chunks called packets and each packet is handled separately.
Each packet contains information about who sent it and where it's going. The most
important advantage of breaking data into individually addressed packets is that packets
from many ongoing exchanges can travel on one wire, which makes it much cheaper to
build a network: many computers can share the same wire without interfering. (In
contrast, when you make a local telephone call within the same exchange on a traditional
phone line, you have essentially reserved a wire from your phone to the phone of the
person you're calling. When all the wires are in use, as sometimes happens during a
major emergency or holiday, not everyone who picks up a phone will get a dial tone. If
you stay on the line, you'll eventually get a dial tone when a line becomes free. In some
countries with worse phone service than the United States, it's not uncommon to have
to wait half an hour or more for a dial tone.) Another advantage of packets is that
checksums can be used to detect whether a packet was damaged in transit.
We're still missing one important piece: some notion of what computers need to say to
pass data back and forth. A protocol is a precise set of rules defining how computers
communicate: the format of addresses, how data is split into packets, and so on. There
are many different protocols defining different aspects of network communication. For
example, the Hypertext Transfer Protocol (HTTP) defines how web browsers and
Search WWH ::




Custom Search