[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: codeComplete does nothing!

Having copied ResultCollector the value of fResult is set in the declaration
initializer.
Kai

"ben cowley" <ben.cowley@xxxxxxxxxx> wrote in message
news:ajvvf2$21v$1@xxxxxxxxxxxxxxxx
> Hi all,
> I'm trying to get context information from the compilation unit in my
> current editor, and I've done
> c.codeComplete(myCompletionRequestor, offset)
> and then tried to get info back from the CompletionRequestor that I
> instantiated. myCompletionRequestor extends CompletionRequestorAdapter and
> basically uses the code from the jdt.ui completion requestor class,
> ResultCollector.
> So I was able to call
> JavaCompletionProposal[] jprop = myCompletionRequestor.getResults()
> but jprop comes back with a length of 0.
> My problem is that Ive looked into getResults() and it is extracting
> information from an array of ArrayList's called fResults. I then went to
> look in codeComplete(), and its super declaration and the important
methods
> called therein, and I cant find where fResults might have been
initialised.
> So the fact that fResults is null for a valid CompilationUnit is what I
need
> to fix, but I need to know how to do that.
>
> Thanks a lot.
>
>