DocumentCode :
3032998
Title :
An empirical study of the use of friends in C++ software
Author :
English, Michael ; Buckley, Jim ; Cahill, Tony ; Lynch, Kristian
Author_Institution :
Dept. of Comput. Sci. & Inf. Syst., Limerick Univ., Ireland
fYear :
2005
fDate :
15-16 May 2005
Firstpage :
329
Lastpage :
332
Abstract :
A commonly held belief is that the friend construct in C++ is a violation of encapsulation. However, little empirical analysis of its use has taken place to provide evidence to support this claim. This paper presents a study, which assesses the design implications of including friendship in a system. A number of hypotheses are investigated based on previous work in this area by Counsell and Newson (2000). Our initial findings suggest that classes declared as friends are coupling hotspots, that the more friends a class has the more protected and private members it will contain and that friendship is not used to access inherited protected members.
Keywords :
inheritance; object-oriented programming; C++ software; design implication; empirical study; friend construct; inheritance; object-oriented software; private member; protected member; Computer science; Conferences; Encapsulation; Endocrine system; Information systems; Protection; Software systems; Testing;
fLanguage :
English
Publisher :
ieee
Conference_Titel :
Program Comprehension, 2005. IWPC 2005. Proceedings. 13th International Workshop on
ISSN :
1092-8138
Print_ISBN :
0-7695-2254-8
Type :
conf
DOI :
10.1109/WPC.2005.7
Filename :
1421048
Link To Document :
بازگشت