>>>>> "Allan" == Allan Stanley <[EMAIL PROTECTED]> writes:

  Allan> Sorry that wasn't clear.  I understand the desired feature.
  Allan> My point was that a completion algorithm that needs to
  Allan> validate a dynamically constructed fully qualified type can
  Allan> use reflection.  For example, class.forName(packageName + "."
  Allan> + simpleClassName) where packageName runs over all packages
  Allan> in the current import declarations of the compilation unit.
  Allan> This only handles completions that can be resolved by
  Allan> considering the current imports, but that's a pretty common
  Allan> case.

 

                Well I agree. Thats why I was suggesting the 
Package.getAllPackages().

                There is one main advantage doing this which is
that some classes have large static initialiser's (I have one for 
instance which takes about 1 minute to load!), and the Class.forName
lookup would I think force this loading. By the nature of things this
could happen accidentally if you're type had the same class name as
one in another package. 

               Hmmm.

               Phil

Reply via email to