SHARE
TWEET

うんちゃん

a guest Jun 13th, 2019 86 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # 2099
  2. - **DRY**: Don't Repeat Yourself
  3.   - Refactor the common functionality into one method, if copies in same class
  4.   - Inheritance for multiple classes
  5. - **Technical Debt**
  6.   - Things being harder to maintain in the long run
  7. - No point of JavaDoc-ing private attributes
  8. - **Fail-fast**
  9.   - catch the error as soon as you can, stop everything to avoid a flawed process
  10. - **Defensive copying**
  11.   - return a copy of something rather than the reference to stop other classes from modifying it
  12. - **Pre-conditions**
  13.   - Handled using `Exceptions` or `Assertions`
  14. - **Associations vs Dependencies**
  15. - **Dependency Inversion**
  16.   - You have two things that inherit from one thing
  17.   - Make a superclass
  18.   - Have the dependencies move to that
  19.  
  20. ```
  21.  test = "gtgtgtgt"
  22. ```
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top