Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Class inheritance.  RSS feed

 
Sunali Anu
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Want to know from which class a String Class is inherited.
 
marc weber
Sheriff
Posts: 11343
Java Mac Safari
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you check the API documentation for String, you will see that String inherits directly from Object...

If there are direct known subclasses, these are also listed in the API. None are shown for String.
 
Jesper de Jong
Java Cowboy
Sheriff
Posts: 16026
87
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The API documentation also mentiones that class String is final, which means that it cannot be subclassed - so there are no classes that extend String.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!