کد مقاله کد نشریه سال انتشار مقاله انگلیسی نسخه تمام متن
417478 681527 2007 19 صفحه PDF دانلود رایگان
عنوان انگلیسی مقاله ISI
Multiple dispatch in reflective runtime environment
موضوعات مرتبط
مهندسی و علوم پایه مهندسی کامپیوتر نظریه محاسباتی و ریاضیات
پیش نمایش صفحه اول مقاله
Multiple dispatch in reflective runtime environment
چکیده انگلیسی

Message dispatch in object-oriented programming (OOP) involves target method lookup in dispatch table/tree. Reflective environment builds dispatch data-structure at runtime as types can be added at runtime. Hence, algorithms for reflective environments require dynamic data structure for dispatch. In this paper, we propose a tree-based algorithm for multiple dispatch in reflective runtime environment. New classes can be added to the system at runtime. Proposed algorithm performs lookup in time proportional to log(n)log(n) times the polymorphic arguments, where n is number of classes in a system. Proposed algorithm uses type-safe approach for multimethod lookup resolving ambiguities. We compare performance of the proposed algorithm with the dispatch mechanism in commonly used virtual/reflexive systems, e.g., Java and Microsoft's Common Language Runtime (MS-CLR), in respect of efficiency and type-safety.

ناشر
Database: Elsevier - ScienceDirect (ساینس دایرکت)
Journal: Computer Languages, Systems & Structures - Volume 33, Issue 2, July 2007, Pages 60–78
نویسندگان
, ,