I have know that we can constrain a sub-class override a method by extends an abstract class or implement an interface. However, it can't rule the sub-class how to override this method. Now, I want any sub-class must override such method with some rules, for example, handle with a variable. Any idea about this?
Not sure what you are asking but if you are asking if you can force a child class to call certain methods then that is not possible.