Skip to main content Accessibility help
×
Hostname: page-component-7479d7b7d-t6hkb Total loading time: 0 Render date: 2024-07-10T16:28:08.503Z Has data issue: false hasContentIssue false

17 - Association and Dictionary

from PART TWO - DATA STRUCTURES

Published online by Cambridge University Press:  05 June 2012

Richard Wiener
Affiliation:
University of Colorado, Colorado Springs
Lewis J. Pinson
Affiliation:
University of Colorado, Colorado Springs
Get access

Summary

We are all familiar with the concept of a dictionary as a fairly large book containing words and definitions. The words are always in alphabetical order to help us look up a particular word. Having the words in alphabetical order is a convenient feature but is not required. There may be other ways to find words in the dictionary, especially if our dictionary is in electronic form. Most words in a dictionary have several definitions. We associate each word with its definitions. Thus, we may characterize a dictionary as a container (possibly ordered) of associations between words and their meanings.

To take our reasoning a step further in our attempt to understand the required behavior of a dictionary, we never add definitions to a dictionary unless they are associated with a word. On the other hand, as we are building the dictionary we may add words without definitions on the promise that the definitions will be added later for those words. And finally, as we fine tune our understanding, we may change definitions for words that are already in the dictionary. We may wish to remove entries in the dictionary or access them in various ways. For example, we may wish to access a list of the words only, the meanings only, or the entire list of entries.

In Chapter 10 we defined interface Dictionary as an extension of the Container interface, interface OrderedDictionary as an extension of SearchTable, and supporting class Association.

Type
Chapter
Information
Publisher: Cambridge University Press
Print publication year: 2000

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

Save book to Kindle

To save this book to your Kindle, first ensure coreplatform@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

  • Association and Dictionary
  • Richard Wiener, University of Colorado, Colorado Springs, Lewis J. Pinson, University of Colorado, Colorado Springs
  • Book: Fundamentals of OOP and Data Structures in Java
  • Online publication: 05 June 2012
  • Chapter DOI: https://doi.org/10.1017/CBO9780511807176.018
Available formats
×

Save book to Dropbox

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.

  • Association and Dictionary
  • Richard Wiener, University of Colorado, Colorado Springs, Lewis J. Pinson, University of Colorado, Colorado Springs
  • Book: Fundamentals of OOP and Data Structures in Java
  • Online publication: 05 June 2012
  • Chapter DOI: https://doi.org/10.1017/CBO9780511807176.018
Available formats
×

Save book to Google Drive

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.

  • Association and Dictionary
  • Richard Wiener, University of Colorado, Colorado Springs, Lewis J. Pinson, University of Colorado, Colorado Springs
  • Book: Fundamentals of OOP and Data Structures in Java
  • Online publication: 05 June 2012
  • Chapter DOI: https://doi.org/10.1017/CBO9780511807176.018
Available formats
×