Chapter Dynamic Dispatch for Method Contracts Through Abstract Predicates
dc.contributor.author | Mostowski, Wojciech | |
dc.contributor.author | Ulbrich, Mattias | |
dc.date.accessioned | 2020-03-18 13:36:15 | |
dc.date.accessioned | 2020-04-01T13:03:06Z | |
dc.date.accessioned | 2018-03-03 23:55 | |
dc.date.accessioned | 2020-03-18 13:36:15 | |
dc.date.accessioned | 2020-04-01T13:03:06Z | |
dc.date.accessioned | 2018-02-01 23:55:55 | |
dc.date.accessioned | 2020-03-18 13:36:15 | |
dc.date.accessioned | 2020-04-01T13:03:06Z | |
dc.date.available | 2020-04-01T13:03:06Z | |
dc.date.issued | 2017 | |
dc.identifier | 644831 | |
dc.identifier | OCN: 1030820407 | en_US |
dc.identifier.uri | http://library.oapen.org/handle/20.500.12657/30616 | |
dc.description.abstract | Dynamic method dispatch is a core feature of object-oriented programming by which the executed implementation for a polymorphic method is only chosen at runtime. In this paper, we present a specification and verification methodology which extends the concept of dynamic dispatch to design-by-contract specifications. The formal specification language JML has only rudimentary means for polymorphic abstraction in expressions. We promote these to fully flexible specification-only query methods called model methods that can, like ordinary methods, be overridden to give specifications a new semantics in subclasses in a transparent and modular fashion. Moreover, we allow them to refer to more than one program state which give us the possibility to fully abstract and encapsulate two-state specification contexts, i.e., history constraints and method postconditions. Finally, we provide an elegant and flexible mechanism to specify restrictions on specifications in subtypes. Thus behavioural subtyping can be enforced, yet it still allows for other specification paradigms. We provide the semantics for model methods by giving a translation into a first order logic and according proof obligations. We fully implemented this framework in the KeY program verifier and successfully verified relevant examples. We have also implemented an extension to KeY to support permission-based verification of concurrent Java programs. In this context model methods provide a modular specification method to treat code synchronisation through API methods. | |
dc.language | English | |
dc.subject.classification | thema EDItEUR::U Computing and Information Technology | en_US |
dc.subject.other | dispatch | |
dc.subject.other | encapsulation | |
dc.subject.other | ghost | |
dc.subject.other | dispatch | |
dc.subject.other | encapsulation | |
dc.subject.other | ghost | |
dc.subject.other | Boolean data type | |
dc.subject.other | Dynamic dispatch | |
dc.subject.other | First-order logic | |
dc.subject.other | Inheritance (object-oriented programming) | |
dc.subject.other | Java Modeling Language | |
dc.subject.other | KeY | |
dc.subject.other | Liskov substitution principle | |
dc.subject.other | Postcondition | |
dc.subject.other | Predicate (mathematical logic) | |
dc.title | Chapter Dynamic Dispatch for Method Contracts Through Abstract Predicates | |
dc.type | chapter | |
oapen.identifier.doi | 10.1007/978-3-319-46969-0 7 | |
oapen.relation.isPublishedBy | 6c6992af-b843-4f46-859c-f6e9998e40d5 | |
oapen.relation.isPartOfBook | a327be69-274f-41cf-9fb4-9aa085dab800 | |
oapen.relation.isFundedBy | 7292b17b-f01a-4016-94d3-d7fb5ef9fb79 | |
oapen.collection | European Research Council (ERC) | |
oapen.pages | 30 | |
oapen.chapternumber | 1 | |
oapen.grant.number | 258405 | |
oapen.grant.acronym | VERCORS | |
oapen.grant.program | FP7 | |
oapen.remark.public | Relevant Wikipedia pages: Boolean data type - https://en.wikipedia.org/wiki/Boolean_data_type; Dynamic dispatch - https://en.wikipedia.org/wiki/Dynamic_dispatch; First-order logic - https://en.wikipedia.org/wiki/First-order_logic; Inheritance (object-oriented programming) - https://en.wikipedia.org/wiki/Inheritance_(object-oriented_programming); Java Modeling Language - https://en.wikipedia.org/wiki/Java_Modeling_Language; KeY - https://en.wikipedia.org/wiki/KeY; Liskov substitution principle - https://en.wikipedia.org/wiki/Liskov_substitution_principle; Postcondition - https://en.wikipedia.org/wiki/Postcondition; Predicate (mathematical logic) - https://en.wikipedia.org/wiki/Predicate_(mathematical_logic) | |
oapen.identifier.ocn | 1030820407 |