Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- abstract class Super {
- protected void finalize() {
- }
- public void doThings() {
- // do stuff
- finalize();
- }
- }
- class Sub extends Super {
- @Override
- protected void finalize() {
- closeSockets();
- alertSomeone();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement