Skip to content

SmartsquareGmbH/composition-over-inheritance

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kotlinish composition over inheritance

This is a small example of the composition over inheritance principle in kotlin.

This repository contains a CountingSet which keeps track of the total number of added elements. The inheritance based approach has one failing test left because the addAll-method do not work like expected. This problem can be solved using the by keyword in kotlin.

📚 Resources

About

Composition over inheritance using kotlin delegation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages