Skip to content
This repository has been archived by the owner on Feb 21, 2024. It is now read-only.

Latest commit

 

History

History
11 lines (6 loc) · 349 Bytes

File metadata and controls

11 lines (6 loc) · 349 Bytes

Chapter 7: Structuring Data with Java

7.10 Storing Strings in Properties and Preferences

Problem

You need to store keys and values that are both strings, possibly with persistence across runs of a program—for example, program customization.

Solution

Use a java.util.prefs.Preferences object or a java.util.Properties object.