About: Friend function     Goto   Sponge   NotDistinct   Permalink

An Entity of Type : dbo:AcademicJournal, 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%2FFriend_function

In object-oriented programming, a friend function, that is a "friend" of a given class, is a function that is given the same access as methods to private and protected data. A friend function is declared by the class that is granting access, so friend functions are part of the class interface, like methods. Friend functions allow alternative syntax to use objects, for instance f(x) instead of x.f, or g(x,y) instead of x.g(y). Friend functions have the same implications on encapsulation as methods. A similar concept is that of friend class.

AttributesValues
rdf:type
rdfs:label
  • Friend-Funktion (de)
  • Friend function (en)
  • Funkcja zaprzyjaźniona (pl)
  • 友元函数 (zh)
rdfs:comment
  • In object-oriented programming, a friend function, that is a "friend" of a given class, is a function that is given the same access as methods to private and protected data. A friend function is declared by the class that is granting access, so friend functions are part of the class interface, like methods. Friend functions allow alternative syntax to use objects, for instance f(x) instead of x.f, or g(x,y) instead of x.g(y). Friend functions have the same implications on encapsulation as methods. A similar concept is that of friend class. (en)
  • Funkcja zaprzyjaźniona – funkcja, która ma dostęp do prywatnych składników klasy. (pl)
  • 在物件導向程式設計中,友誼函數(friend function)是一個指定類別(class)的“朋友”,该函數被允許存取該類別中private、protected、public的資料成員。普通的函數並不能存取private和protected的資料成員,然而宣告一个函數成为一個類別的友誼函數則被允許存取private以及protected的資料成員。 友誼函數的宣告可以放在類別宣告的任何地方,不受存取限定关键字private、protected、public的限制。一个相似的概念是。 友誼關鍵字應該谨慎使用。如果一个拥有private或者protected成员的類別,宣告過多的友誼函數,可能會降低封装性的價值,也可能對整個設計框架產生影響。 (zh)
  • Unter einer Friend-Funktion oder Friend-Methode versteht man in der objektorientierten Programmierung eine Methode, Funktion oder Prozedur, der man erlaubt, auf private (private) oder geschützte (protected) Daten einer anderen Klasse zuzugreifen, auf die sie sonst keinen Zugriff hätte. Diese Möglichkeit der Freundschaft sollte mit Bedacht genutzt werden, da dadurch die Datenkapselung abgeschwächt wird.Friend-Methoden sind ein Konzept der Programmiersprache C++. Jedoch gibt es ähnliche Möglichkeiten in anderen objektorientierten Programmiersprachen (zum Beispiel internal in C#). (de)
dcterms:subject
Wikipage page ID
Wikipage revision ID
Link from a Wikipage to another Wikipage
Link from a Wikipage to an external page
sameAs
dbp:wikiPageUsesTemplate
has abstract
  • Unter einer Friend-Funktion oder Friend-Methode versteht man in der objektorientierten Programmierung eine Methode, Funktion oder Prozedur, der man erlaubt, auf private (private) oder geschützte (protected) Daten einer anderen Klasse zuzugreifen, auf die sie sonst keinen Zugriff hätte. Ein solcher Zugriff widerspricht dem Paradigma der Datenkapselung, kann aber unter Umständen trotzdem sinnvoll sein. Dann wird die zugreifende Methode mit dem Schlüsselwort friend als ein „Freund“ der darauf zugegriffenen Klasse deklariert. Sie hat dann nicht nur auf öffentliche (public), sondern auch auf geschützte (protected) oder private (private) Informationen in dieser Klasse Zugriff. Diese Möglichkeit der Freundschaft sollte mit Bedacht genutzt werden, da dadurch die Datenkapselung abgeschwächt wird.Friend-Methoden sind ein Konzept der Programmiersprache C++. Jedoch gibt es ähnliche Möglichkeiten in anderen objektorientierten Programmiersprachen (zum Beispiel internal in C#). (de)
  • In object-oriented programming, a friend function, that is a "friend" of a given class, is a function that is given the same access as methods to private and protected data. A friend function is declared by the class that is granting access, so friend functions are part of the class interface, like methods. Friend functions allow alternative syntax to use objects, for instance f(x) instead of x.f, or g(x,y) instead of x.g(y). Friend functions have the same implications on encapsulation as methods. A similar concept is that of friend class. (en)
  • Funkcja zaprzyjaźniona – funkcja, która ma dostęp do prywatnych składników klasy. (pl)
  • 在物件導向程式設計中,友誼函數(friend function)是一個指定類別(class)的“朋友”,该函數被允許存取該類別中private、protected、public的資料成員。普通的函數並不能存取private和protected的資料成員,然而宣告一个函數成为一個類別的友誼函數則被允許存取private以及protected的資料成員。 友誼函數的宣告可以放在類別宣告的任何地方,不受存取限定关键字private、protected、public的限制。一个相似的概念是。 友誼關鍵字應該谨慎使用。如果一个拥有private或者protected成员的類別,宣告過多的友誼函數,可能會降低封装性的價值,也可能對整個設計框架產生影響。 (zh)
gold:hypernym
prov:wasDerivedFrom
page length (characters) of wiki page
foaf:isPrimaryTopicOf
is Link from a Wikipage to another Wikipage of
is Wikipage disambiguates of
is foaf:primaryTopic of
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, 67 GB memory in use)
Data on this page belongs to its respective rights holders.
Virtuoso Faceted Browser Copyright © 2009-2024 OpenLink Software