Whats the difference between toModelElementArray and ToAllLevelModelElementArray


#1

Hi guys,
When we retrieve model elements of a project by using project.toModelElementArray method, some model elements of project wont retrieve otherwise when using project.toAllLevelModelElementArray more model elements retrieve.
I want to know what kinds of model elements will retrieve when we use tomodelElementArray and which one will retrieve by toAllLevelModelElementArray method ?


#2

For examples, there are 5 packages, in 3 levels:
java
java.awt
java.awt.font
java.awt.geom
java.awt.image

IProject #toAllLevelModelElementArray()
returns java, awt, font, geom, image

IProject #toModelElementArray()
returns java

IPackage #toChildArray()
from java, returns awt
from awt, returns font, geom, image


#3

Thanks :pray: