Wednesday, July 22, 2026
Latest:
  • Präsentation für b1
  • Verb “werden” Konjugation
  • In German, verb sein (to be) Konjunktion
  • Wichtige wörter für B1 prüfung
  • What are the main differences between ApplicationContext and BeanFactory?
Upokary

Upokary

Quality information

  • Health
  • Life
  • Fashion
  • Food
  • Code
  • English
  • বাংলা
Technology 

Design and document for inheritance else prohibit it

Published: March 6, 2020 inheritance, Java

When we are designing a class if it is only for internal use and not for extension then we should make the class final. The effective java book has clearly mentioned this line.

The interaction of inherited classes with their parents can be surprising and unpredictable if the paren class wasn’t designed to be inherited from.

Classes should be two kinds :

  • Classes designed to be extended, and with enough documentation to describe how it should be done
  • Classes marked final

https://stackoverflow.com/questions/218744/good-reasons-to-prohibit-inheritance-in-java

You May Also Like

Minimum Index Sum of Two Lists

December 27, 2022 beroza

Err:1 ec2.archive.ubuntu.com bionic InRelease Temporary failure

June 5, 2020 beroza

Write a Program to Find Two Furthest Houses With Different Colors

January 20, 2023 beroza

could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket

October 11, 2020 beroza

Difference between session.timeout.ms and max.poll.interval.ms for Kafka

June 9, 2020 beroza

Consider implementing comparable of a class in Java

February 6, 2020 beroza

Count Pairs Of Similar Strings

January 6, 2023 beroza

Write a Program to Find N-ary Tree Preorder Traversal

January 8, 2023 beroza

Unable to load script from assets index.android.bundle

December 11, 2018 beroza

Why Upokary?

Upokary.com is a useful application in everyday life. It provides very handy information regarding every aspect of life. Each and every tip of upokary.com is meant to make life better.

Upokary tools

  • Youtube thumbnail
  • Youtube video downloader

Useful Links

  • Handy code
  • Technology
  • People
  • Programming
  • Quote
  • Travel
  • WordPress
  • IELTS
  • Kids

Pages

  • Sitemap
  • Privacy policy
  • About us
  • Contact us

Support

For any kind of query or question please drop a message in the following email: upokary@gmail.com
Copyright © 2026 Upokary. All rights reserved.