We have a Java correspondent Net “mustinherit” or “not inheritable”?
•
Java
How do we declare that a class in Java must inherit rather than instantiate directly from itself, or conversely, how do we force it not to inherit? Yes Net, we can use the "mustinherit" and "notinheritable" modifiers
Solution
Abstract it
Make it final
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码