I came across with following statements while reading the Clean Code book of Robert C. Martin.Chapter : 7 :  Error Handling  Page No : 109  ..In fact, wrapping third-party APIs is a best practice. When you wrap  a third-party API, you minimize your dependencies upon it: You can  choose to move to a different library in the future without much  penalty. Wrapping also makes it easier to mock out third-party calls  when you are testing your own code. One nal advantage of wrapping is  that you arent tied to a particular vendors API design choices. You  can dene an API that you feel comfortable with.I am quite confused about the bold part.I am totally clueless how can we move to different library so easily if we wrap the third party library and how testing becomes easy with it ?
Wrapping third party library is best practice
java;third party libraries
Imagine you have a complicated library that you depend on. Say the library exposes four different calls to its functionality, and your code base uses each of them three times.If you use the raw vendor API in your code, then if the vendor library changes or you have to replace it, you'll have to change twelve API calls in your code base. If you had an abstraction layer between your code and their code, you'd have to change four places in the abstraction layer and none at all in your code base. You can see that this saves effort - the more effort the more calls the API offers. And most real-world APIs offer more than four entry points.