Is String a primitive or an Object in Android or Java?

后端 未结 6 1367
無奈伤痛
無奈伤痛 2020-12-14 18:12

In the Android API http://developer.android.com/guide/topics/data/data-storage.html#pref

It says:

Shared Preference allows you to save and re

6条回答
  •  别那么骄傲
    2020-12-14 18:31

    Straight from JLS:

    A string literal is a reference to an instance of class String
    

    So no it is not a primitive.

提交回复
热议问题