Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Abstraction (computer science)
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Abstraction features== ===Programming languages=== {{Further|Programming language}} Different programming languages provide different types of abstraction, depending on the intended applications for the language. For example: * In [[object-oriented programming]] languages such as [[C++]], [[Object Pascal]], or [[Java (programming language)|Java]], the concept of ''abstraction'' has become a declarative statement β using the [[Syntax (programming languages)|syntax]] <code>''function''(''parameters'') = 0;</code> (in [[C++]]) or the [[reserved word]]s (keywords) ''<code>abstract</code>''<ref name="Oracle Java abstract">{{cite web |url=http://docs.oracle.com/javase/tutorial/java/IandI/abstract.html |title=Abstract Methods and Classes|website=The Java Tutorials |publisher=Oracle |access-date=4 September 2014}}</ref> and ''<code>interface</code>''<ref name="Oracle Java interface">{{cite web |url=http://docs.oracle.com/javase/tutorial/java/IandI/interfaceAsType.html |title=Using an Interface as a Type|website=The Java Tutorials |publisher=Oracle |access-date=4 September 2014}}</ref> (in [[Java (programming language)|Java]]). After such a declaration, it is the responsibility of the programmer to implement a [[Class (computer science)|class]] to instantiate the [[Object (computer science)|object]] of the declaration. * [[Functional programming]] languages commonly exhibit abstractions related to functions, such as [[lambda abstraction]]s (making a term into a function of some variable) and [[higher-order function]]s (parameters are functions).<ref>{{FOLDOC|Abstraction}}</ref><!-- This has to be merged in the following sections. --> * Modern members of the [[List of Lisp-family programming languages|Lisp programming language family]] such as [[Clojure]], [[Scheme (programming language)|Scheme]] and [[Common Lisp]] support [[Macro (computer science)#Syntactic macros|macro systems]] to allow syntactic abstraction. Other programming languages such as [[Scala (programming language)|Scala]] also have macros, or very similar [[metaprogramming]] features (for example, [[Haskell]] has [[Template Haskell]], [[OCaml]] has [[MetaOCaml]]). These can allow programs to omit [[boilerplate code]], abstract away tedious function call sequences, implement new [[control flow]] structures, and implement [[domain-specific language]]s (DSLs), which allow domain-specific concepts to be expressed in concise and elegant ways. All of these, when used correctly, improve both the programmer's efficiency and the clarity of [[source code]] by making the intended purpose more explicit. A consequence of syntactic abstraction is also that any Lisp dialect, and almost any programming language, can in principle, be implemented in any modern Lisp with significantly reduced (but still non-trivial in most cases) effort when compared to "more traditional" programming languages such as [[Python (programming language)|Python]], [[C (programming language)|C]] or [[Java (programming language)|Java]]. ===Specification methods=== {{Further|Formal specification}} Analysts have developed various methods to formally specify software systems. Some known methods include: * Abstract-model based method (VDM, Z); * Algebraic techniques (Larch, CLEAR, OBJ, ACT ONE, CASL); * Process-based techniques (LOTOS, SDL, Estelle); * Trace-based techniques (SPECIAL, TAM); * Knowledge-based techniques (Refine, Gist). ===Specification languages=== {{Further|Specification language}} Specification languages generally rely on abstractions of one kind or another, since specifications are typically defined earlier in a project, (and at a more abstract level) than an eventual implementation. The [[Unified Modeling Language]] (UML) specification language, for example, allows the definition of ''abstract'' classes, which in a waterfall project, remain abstract during the architecture and specification phase of the project.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)