next up previous top
Next: Match
Up: Property
Previous: Library

MapsTo

Description

The MapsTo property is used to further specify an abstraction bind in the composite implementation of a component. The value part of the property is a list of dot-separated pairs or triples of <identifier>s that name players in the composite implementation. Identifier pairs name non-PLBundle players in components that have been previously instantiated. Identifier triples name Member players in PLBundle players in previously instantiated components.

The MapsTo property associates the set of internal players specified in its value part to the external player named in the abstraction bind. An external player is a player exposed in the interface of a component, and an internal player is one that is exposed in the interface of another component that has been instantiated inside the implementation of a component. A bind, therefore, maps a player in the interface of a component to one or more players in its composite implementation.

There are two forms of the <bind> statement: the simple bind, and the abstraction bind. When a player in the interface is implemented by a single player in the implementation having the same type, then the system designer uses the simple bind syntax. This form of the bind is a simple aliasing operation.

When the player in the interface is implemented by a collection of players in the implementation, or a single player with a different type, then the system designer uses the abstraction bind syntax. An abstraction bind does not represent a simple aliasing operation. It is an association of players in the implementation to a player in the interface. The list of players in the MapsTo property represents an abstraction of some form. For example, the players may collectively represent some abstract operation as a group - an operation that is accessible via a single player in the interface of the component. In other cases, the player(s) in the MapsTo list may represent a concrete implementation of a more abstract behavior of a player in the interface (i.e., a behavior not directly supported in a given programming language). For example, a stream player in the interface of a Filter component that has a composite implementation may actually be implemented by procedure call players in the implementation (e.g., to routines like fgets or fprintf in the C language). The behavior of a stream in the interface is actually an abstraction implemented by procedure calls in the implementation in this case.

The MapsTo property is required in an abstraction bind. It is an integral part of the specification of the bind itself.

Property Lists

The MapsTo property can legally be specified in the property list in the following UniCon language element:

Value Syntax

The syntax of the value part of the MapsTo property is a semicolon-separated list of dot-separated pairs or triples of <identifier>s, enclosed in parentheses.

Required Rule

Required

Merge Rule

MERGE

More than one specification of the MapsTo property in a single property list is treated as a single specification with the union of all values in all of the specifications.

Semantic Checks

The following are the semantic checks performed on the value of the MapsTo property:

  1. The first <identifier> in each dot-separated pair or triple must name a component that has been previously instantiated in the composite implementation.

  2. The second <identifier> in each dot-separated pair or triple must name a player in the interface of the component instantiation named by the first <identifier>.

  3. If an item in the MapsTo list is a triple of <identifier>s, the second <identifier> must name a player of type PLBundle.

  4. If an item in the MapsTo list is a triple of <identifier>s, the third
    <identifier> must name a player in the PLBundle player named by the second <identifier>.

Example

The following are examples of the specification of the MapsTo property. They are embedded in two abstraction bind statements in the composite implementation of a Filter component:

  IMPLEMENTATION IS
    USES main INTERFACE Sort_Main
    USES sort INTERFACE Sort
    USES libc INTERFACE Libc

    BIND input TO ABSTRACTION
      MAPSTO (main.libc.fgets)
    END input
    BIND output TO ABSTRACTION
      MAPSTO (main.libc.fprintf)
    END output

    ESTABLISH C-PLBundler WITH 
      main.sort_routines AS participant
      sort.sort_routines AS participant
    END C-PLBundler

    ESTABLISH C-PLBundler WITH 
      main.libc AS participant
      libc.libc AS participant
    END C-PLBundler
  END IMPLEMENTATION

next up previous top
Next: Match
Up: Property
Previous: Library

Comments? Mail the current maintainer of this page.

Author: Gregory Zelesnik

Last Modified: May 12, 1996