Using roles in Java

  • Authors:
  • Michael Schrefl;Thomas Thalhammer

  • Affiliations:
  • University of Linz, Data & Knowledge Engineering, Altenberger Straßße 69, A-4040 Linz, Austria;SPAR Österreichische Warenhandels-AG, Europastraße 3, A-5015 Salzburg, Austria

  • Venue:
  • Software—Practice & Experience - Research Articles
  • Year:
  • 2004

Quantified Score

Hi-index 0.00

Visualization

Abstract

Using roles in object-oriented design leads to a more natural representation of a given problem domain. Despite a lot of research into role–based systems, there is still a gap between conceptual representations of roles and the usage of roles in strongly typed object-oriented programming languages such as C++ or Java. Since these languages associate classes and their instances exclusively and permanently, representing evolving objects that may take on different roles over time is difficult without special support: (i) entities must be reclassified any time they evolve and (ii) class hierarchies may grow exponentially if entities may take on several independent roles.This article shows how role hierarchies can be easily implemented in Java. It introduces the Java Role Package, which provides a set of classes to support handling of evolving objects without modifying the semantics of Java itself. Copyright © 2004 John Wiley & Sons, Ltd.