Database structure example, Database structure example 1 – Apple Network Setup User Manual

Page 17

Advertising
background image

C H A P T E R 1

About Network Setup

Network Setup Database Fundamentals

17

one

active set entity

. The entities referenced by the active set entity

comprise the active network preferences. All set entities have the same
type.

icon.

An entity can include a reference to a custom icon. The custom icon is

not currently used, but may be used by future system software to display a
visual representation of the entity.

Within each entity there are zero or more

preferences

, distinguished by a

preference type

(an

OSType

). A preference is the atomic unit of data in the

database. When you read or write data, you do so one preference at a time.
Typically the data for a preference is protocol-dependent. Its format is
determined by the entity class and type and by the preference type itself. To
read or write a preference meaningfully, you must know the format of the
preference data. The reference section of this document describes the format of
every preference used by the Apple protocol stacks. In most cases, this
description includes a C structure that mirrors the structure of the preference
itself.

Note

For most preferences, the data format is the same as for the
equivalent resource in the legacy preference files. If you are
familiar with the legacy file format, you should be able to
easily understand the preference data format. See “Legacy
Issues” (page 21) for mor
e information on how Network
Setup synchronizes the database with the legacy
preferences files.

Database Structure Example

1

Figure 1-5 shows an example of how the Network Setup database might be
structured on a particular computer.

Advertising