Suppose you are writing a software where there is a popular existing library that does not have all the algorithms/features you want but provides some "vocabulary" (equivalents of std::vector/std::string for domain) types you could use.
Should you use that library and be tied to it or write your own types you use on for interface function signatures(with option to convert to 3rd party lib quickly - so there is no noticeable performance difference).
From what I see benefits of using 3rd party lib:
- Cheaper(no development cost, only adoption/usage cost)
- Probably much better documented/less bugs
- Less spam in code
void Do(MyX& x) { ThirdPartyX xtp(x); ThirdPartyAlg(xtp);...}
- No surprises(if your types behave slightly different than 3rd party types new hires with experience with 3rd party may be surprised)
From what I see problems of using 3rd party lib:
- Hard to switch away
- Might not fit your problems perfectly/might make tradeoffs you do not like
I do not care about cost of installing/maintaining third party lib since of large projects cost is negligible.
Assume that 3rd party library is well maintained, so not some guy's github repo that had last commit 5 years ago.