User Tools

Site Tools


notes:cprog:spring2024:projects:cppx

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Last revisionBoth sides next revision
notes:cprog:spring2024:projects:cppx [2024/04/17 15:17] – [Access Control] amelvil2notes:cprog:spring2024:projects:cppx [2024/04/24 12:22] – [Access Control] amelvil2
Line 155: Line 155:
  
 Class members declared as ''public'' can be used by any function. Class members declared as ''public'' can be used by any function.
 +
 +For example:
  
 <code> <code>
Line 166: Line 168:
  
 Class members declared as ''private'' can be used only by member functions and friends (classes or functions) of the class. Class members declared as ''private'' can be used only by member functions and friends (classes or functions) of the class.
 +
 +For example:
  
 <code> <code>
Line 177: Line 181:
  
 Class members declared as ''protected'' can be used by member functions and friends (classes or functions) of the class. Additionally, they can be used by classes derived from the class. Class members declared as ''protected'' can be used by member functions and friends (classes or functions) of the class. Additionally, they can be used by classes derived from the class.
 +
 +For example:
  
 <code> <code>
notes/cprog/spring2024/projects/cppx.txt · Last modified: 2024/04/24 12:23 by amelvil2