About: Subtyping     Goto   Sponge   NotDistinct   Permalink

An Entity of Type : yago:WikicatProgrammingParadigms, within Data Space : dbpedia.demo.openlinksw.com associated with source document(s)
QRcode icon
http://dbpedia.demo.openlinksw.com/describe/?url=http%3A%2F%2Fdbpedia.org%2Fresource%2FSubtyping

In programming language theory, subtyping (also subtype polymorphism or inclusion polymorphism) is a form of type polymorphism in which a subtype is a datatype that is related to another datatype (the supertype) by some notion of substitutability, meaning that program elements, typically subroutines or functions, written to operate on elements of the supertype can also operate on elements of the subtype. If S is a subtype of T, the subtyping relation (written as S <: t, s ⊑ t, or s ≤: t ) means that any term of type s can safely be used in any context where a term of type t is expected. the precise semantics of subtyping here crucially depends on the particulars of how "safely be used" and "any context" are defined by a given type formalism or programming language. the type system of a p

AttributesValues
rdf:type
rdfs:label
  • Πολυμορφισμός υποτύπων (el)
  • Sottotipo (informatica) (it)
  • サブタイピング (計算機科学) (ja)
  • Podtyp (programowanie) (pl)
  • Subtyping (en)
  • Polymorfism (programmering) (sv)
  • 子类型 (zh)
rdfs:comment
  • サブタイピング(英: subtyping)や部分型とは、型のポリモーフィズムの形態であり、上位と定義された型を、その下位と定義された型で、型安全性に則って代替できるというの概念および実装を意味している。 スーパータイプは、そのサブタイプの数々によって代替/代入可能とされており、これは代入可能性(substitutability)と呼ばれる。そのスーパータイプとサブタイプの関係は、is-aとも言われる。記号<:を用いてsubtype <: supertypeと表記される。 スーパータイプ+サブタイプの概念はその時の用法で、上位型(supertype)+下位型(subtype)、基底型(base type)+派生型(derived type)、基本型(basic type)+拡張型(extend type)、上位型(supertype)+部分型(subtype) などの別称に使い分けられており、それぞれの性質にも差異がある。 (ja)
  • 在编程语言理论中,子类型(动名词,英語:subtyping)是一种类型多态的形式。这种形式下,子类型(名词,英語:subtype)可以替换另一种相关的数据类型(超类型,英語:supertype)。也就是说,针对超类型元素进行操作的子程序、函数等程序元素,也可以操作相应的子类型。如果 S 是 T 的子类型,这种子类型关系通常写作 S <: T,意思是在任何需要使用 T 类型对象的环境中,都可以安全地使用 S 类型的对象。子类型的准确语义取决于具体的编程语言中「X 环境中,可以安全地使用 Y」的意义。编程语言的类型系统定义了各自不同的子类型关系。 由于子类型关系的存在,某个对象可能同时属于多种类型,因此,子类型(英語:subtyping)是一种类型多态的形式,也被称作子类型多态(英語:subtype polymorphism)或者包含多态(英語:inclusion polymorphism)。在面向对象程序设计中,多态一般仅指这里所说的「子类型多态」,而「参数多态」则一般被称作泛型编程。 子类型与面向对象语言中(类或对象)的继承是两个概念。子类型反映了类型(即面向对象中的接口)之间的关系;而继承反映了一类对象可以从另一类对象创造出来,是语言特性的实现。因此,子类型也称接口继承;继承称作实现继承。 (zh)
  • Στην θεωρία γλωσσών προγραμματισμού, πολυμορφισμός υποτύπων είναι μια μορφή πολυμορφισμού τύπων στην οποία ένας υποτύπος είναι ένας τύπος δεδομένων που σχετίζεται σε έναν άλλο τύπο δεδομένων (τον υπερτύπο) με ενός είδους , πράγμα που σημαίνει ότι οι δομές του προγράμματος, συνήθως υπορουτίνες ή συναρτήσεις που γράφτηκαν για να λειτουργούν πάνω σε στοιχεία του υπερτύπου μπορούν επίσης να λειτουργήσουν με τα στοιχεία του υποτύπου. Αν S είναι ένας υποτύπος του Τ, η υποτύπου γράφεται συχνά S <: Τ, που σημαίνει ότι οποιοσδήποτε όρος του τύπου S μπορεί "να χρησιμοποιηθεί με ασφάλεια σε ένα πλαίσιο όπου" αναμένεται ένας όρος του τύπου Τ. Οι ακριβής σημασιολογία του πολυμορφισμού υποτύπων εξαρτάται σε μεγάλο βαθμό από το τι ακριβώς σημαίνει "μπορεί να χρησιμοποιηθεί με ασφάλεια σε ένα πλαίσιο όπο (el)
  • In programming language theory, subtyping (also subtype polymorphism or inclusion polymorphism) is a form of type polymorphism in which a subtype is a datatype that is related to another datatype (the supertype) by some notion of substitutability, meaning that program elements, typically subroutines or functions, written to operate on elements of the supertype can also operate on elements of the subtype. If S is a subtype of T, the subtyping relation (written as S <: T, S ⊑ T, or S ≤: T ) means that any term of type S can safely be used in any context where a term of type T is expected. The precise semantics of subtyping here crucially depends on the particulars of how "safely be used" and "any context" are defined by a given type formalism or programming language. The type system of a p (en)
  • In informatica, e in particolare in programmazione, si definisce sottotipo un tipo di dato legato ad un altro tipo di dato, detto super-tipo, da una relazione di sostituibilità, intesa nel senso che un programma scritto per utilizzare elementi costruiti sul modello del supertipo, può funzionare anche con elementi costruiti sul modello del sottotipo. In generale, si assume che la relazione supertipo-sottotipo sia quella definita dal principio di sostituzione di Liskov. (it)
  • Podtyp – konstrukcja programistyczna umożliwiająca w określonym języku programowania definiowanie ograniczeń na pewnym typie bazowym. Pojęcie podtypu zdefiniowane zostało wprost w języku Ada, w którym istnieje jednoznaczne odróżnienie deklaracji typu i podtypu, identyfikowane odpowiednim słowem kluczowym: * subtype – dla podtypów w odróżnieniu od * type – dla typów, w tym także typów pochodnych. Przykład w Adzie: <b>subtype</b> <i>miesiąc</i> <b>is</b> INTEGER <b>range</b> 1..12; <b>type</b> <i>miesiąc</i>=1..12; * <b>TYPE</b> <i>miesiąc</i>=1..12 * <b>TYPE</b> <i>miesiąc</i>:INTEGER=1..12 (pl)
  • Polymorfism innebär inom programmering att en symbol, till exempel en variabel, inte har en fix datatyp utan att datatypen kan ändras under programmets gång. Variabeln kan till exempel börja med att vara en enkel variabeltyp, till exempel ett heltal (integer), och sedan bli en sammansatt variabeltyp (till exempel en array, eller ett objekt, eller en array av objekt), eller en funktion. Script-språk som Javascript, Perl, PHP, Python brukar ha polymorfa variabler. Fördelen är större flexibilitet, nackdelen är att man inte har tillgång till strikt typkontroll som hjälpmedel vid avlusning. (sv)
foaf:depiction
  • http://commons.wikimedia.org/wiki/Special:FilePath/Inheritance.svg
dcterms:subject
Wikipage page ID
Wikipage revision ID
Link from a Wikipage to another Wikipage
Faceted Search & Find service v1.17_git139 as of Feb 29 2024


Alternative Linked Data Documents: ODE     Content Formats:   [cxml] [csv]     RDF   [text] [turtle] [ld+json] [rdf+json] [rdf+xml]     ODATA   [atom+xml] [odata+json]     Microdata   [microdata+json] [html]    About   
This material is Open Knowledge   W3C Semantic Web Technology [RDF Data] Valid XHTML + RDFa
OpenLink Virtuoso version 08.03.3330 as of Mar 19 2024, on Linux (x86_64-generic-linux-glibc212), Single-Server Edition (378 GB total memory, 49 GB memory in use)
Data on this page belongs to its respective rights holders.
Virtuoso Faceted Browser Copyright © 2009-2024 OpenLink Software