vendredi 4 août 2017

Does Java reflection getDeclaredFields() return in declaration order? [duplicate]

I am using Field fields[] = myClass.getClass().getDeclaredFields();

I want to know has Array been set in declaration order?

In fields[0], first declared field from class. In fields[1], second field from class, like this. It would be a pleasure for me if you can also explain why. Thanks...





Aucun commentaire:

Enregistrer un commentaire