oop - difference between unidirectional association and dependency -


according wikipedia

dependency relationship shows element, or set of elements, requires other model elements specification or implementation.[1] element dependent upon independent element, called supplier.

so not same unidirectional association? use dependency when operation in 1 class uses object of other class parameter?

how unidirectional association , dependency different. example helpful

association means 2 associated entities linked semantically. dependency declares there a... well, dependency of sort. associations dependencies, while dependency not mean association. example, class 'a' depends on class 'b' if has method takes 'b' , passes argument function in class. if 'a' calls method of class 'b', should modeled association.

disclaimer have read uml specification , asked myself question number of times. arrived @ at definition above, i'm still not sure 100% correct.


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

javascript - Clean way to programmatically use CSS transitions from JS? -

android - send complex objects as post php java -