Software Design/Specify interface contracts

From Wikiversity
Jump to navigation Jump to search

This page augments Design by contract article on Wikipedia.

Why[edit | edit source]

Well-specified interface contracts reduce cases when clients intentionally or unintentionally rely on unspecified behaviour, thus making the client code more robust.

Conversely, when clients don't use unspecified behaviour, maintaining the interface's compatibility doesn't require researching the code of the clients.

Sources[edit | edit source]

  • David Thomas; Andrew Hunt (2019). The Pragmatic Programmer (20th Anniversary ed.). Addison-Wesley Professional. ISBN 978-0135957059.