Search code examples
javafinalaccess-modifiers

Access 'final' modifier class in java


How to access a 'final' modifier class in java? I tried to create an object of that class but it is not accepting. Can anybody tell me that how to initialize or call that class in my own java class.

For example I want to use this class in my own class http://hi-android.info/src/com/android/internal/telephony/CallManager.java.html

Thx in advance


Solution

  • To use the CallManager you linked, simply do the following in your code:

    CallManager manager = CallManager.getInstance();
    

    All public methods defined on the manager will then be available for you to use.