java - IPackageFragment not open when trying to get IPackageFragment with pacakge name -


With the code given below, I am trying to get the IPCageFragment element for a given package name. But the toasting of the ipak fragment () is back com.abc.def (not open). When trying to access the methods of all sections in this package, I get the JavaModel exception.

Note: I can open and view Java files in this package in Eclipse. Let anyone know what is wrong with this package.

  Receives private ipafefrazgrag package (name of string) throws an exception {ipafegraphragment root [] root = project.gatealepackagefragmentput (); (Int ii = 0; ii & lt; roots.length; ii ++) (Ipackage fragment piece = root [ii] .getPackageFragment (name); if (piece! = Null & piece. Axis) {Return slice;}} return tap;}    

navigate to pieces of the package or Before reaching the elements in the package section, you must call open () on the package section.

Comments

Popular posts from this blog

ios - Adding an SKSpriteNode to SKScene from a child SKSpriteNode -

Matlab transpose a table vector -

c# - Textbox not clickable but editable -