Map
Index
Random
Help
Topics
th

Topic: representation data type

topics > computer science > programming > Group: program module



Group:
data type

Topic:
abstract data type
Topic:
data type as a set of values and a set of operations
Topic:
interface between program modules
Topic:
kinds of numbers
Topic:
notation for program clusters
Topic:
primitive data types of a language
Topic:
primitive data types for Thesa
Topic:
range data type
Topic:
ref_any or Object data type

Summary

One way of implementing abstract data types is to define the type of a variable to be the abstract data type outside of the module and a representation type inside of the module. The representation type is made of simple variables, arrays, and pointers.

Within the type definition full use of the representation type is allowed while outside only defined operations are valid. Choice of representation type is independent of the type's use, while uncontrolled operations on pointers and memory are restricted to type definitions. In this way a hierarchy of types is built from a set of basic types. Representation types are often in violation of the uniform language principle since the full power of the language is valid only during type definition. In Russell there is no representation type. Instead objects can be named and public access limited. (cbb 5/80)

At some level, a data object must be manipulated according to the data types provided by a computer. But the data types provided by the computer allow unlimited access to data structures. What's needed is controlled translation between the two views. In Thesa, the definition of an operation is a translation of its title. But what is to prevent use of the definition directly? If there's something to prevent direct use, then how is it allowed within some operations but not within others? This looks like a judgment call which should be left to the users. Inappropriate use would eventually be caught and removed. Any proof of correctness would then depend on a cross-reference. A data type's set of operations can hide the use of the data type in other operations. (cbb 1/90)

Subtopic: specification vs. representation up

Quote: specification types for abstract data types, representation types for implementing them [»boomHJ9_1976]
Quote: should control any dependencies on representation and machine details; better than dirty tricks

Subtopic: correctness up

Quote: a data representation is correct if every procedure models the intended abstract operation and initialization models the abstract, initial value [»hoarCA_1972a]

Subtopic: access to representation up

Quote: rights are amplified on entering a type-module; type is converted to representation type with additional rights [»joneAK4_1976]
Quote: inside a type declaration can use its representation type [»johnRI3_1976, OK]
Quote: sometimes it is necessary to extract the representation pointer from a handle, pass it to a function, or perhaps, rebind it as a new handle [»stroB_1991]
Quote: 'rep' defines a representation type for use within a cluster [»liskB4_1974, OK]

Subtopic: representation type up

Quote: the abstraction function of an abstract type maps abstract values to values of its data structure [»guttJV_2002]
Quote: the representation invariant of an abstract type defines its valid representations as the values of a data structure [»guttJV_2002]
Quote: use macros for operations in the representation type [»kiebRB9_1973, OK]
Quote: in a cluster, use 'cvt' type for parameters which are automatically converted to representation type [»liskBH2_1976, OK]
Quote: a rep-type is the set of modes with the same representation; explicitly declared, includes operations [»parnDL3_1976]
Quote: in Russell, an exports-list defines what is representation and what is visible outside; same as a with-list [»demeA_1978]
Quote: the memory of a class is an elaboration in terms of more primitive objects [»hendP9_1975]

Subtopic: constructor up

Quote: allow "dangerous" constructors inside clusters; for efficient implementation of abstract data types [»berrDM4_1977]

Subtopic: data structure up

Quote: data structures become references to variables, array elements, and pointers [»kiebRB9_1973]

Subtopic: width of data up

Quote: prescribing the number of digits in a date field is a trivial design decision; it is a scandal only because it is expensive to change [»creeC11_1997]

Subtopic: problems with representation up

Quote: abstract data type is difficult to extend; many changes to representation [»cookWR5_1990]
Quote: with abstract data type, a new observation requires access to the representation type [»cookWR5_1990]
Quote: data description does not support collections of data; hard to change without impacting applications [»coddEF6_1970]
Quote: avoid representational dependencies in data; e.g., ordering, indexing, and access path

Related Topics up

Group: data type   (34 topics, 730 quotes)

Topic: abstract data type (64 items)
Topic: data type as a set of values and a set of operations (16 items)
Topic: interface between program modules (55 items)
Topic: kinds of numbers (24 items)
Topic: notation for program clusters (4 items)
Topic: primitive data types of a language (31 items)
Topic: primitive data types for Thesa (82 items)
Topic: range data type (17 items)
Topic: ref_any or Object data type
(9 items)


Updated barberCB 12/04
Copyright © 2002-2008 by C. Bradford Barber. All rights reserved.
Thesa is a trademark of C. Bradford Barber.