Skip to main content

This CGIT instance is deprecated, and repositories have been moved to Gitlab or Github. See the repository descriptions for specific locations.

summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'docs/org.eclipse.wst.jsdt.doc/html/api_reference/org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html')
-rw-r--r--docs/org.eclipse.wst.jsdt.doc/html/api_reference/org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html1174
1 files changed, 0 insertions, 1174 deletions
diff --git a/docs/org.eclipse.wst.jsdt.doc/html/api_reference/org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html b/docs/org.eclipse.wst.jsdt.doc/html/api_reference/org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html
deleted file mode 100644
index a8328a76..00000000
--- a/docs/org.eclipse.wst.jsdt.doc/html/api_reference/org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html
+++ /dev/null
@@ -1,1174 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
-<!--NewPage-->
-<HTML>
-<HEAD>
-<!-- Generated by javadoc (build 1.5.0_12) on Fri May 30 11:15:59 CDT 2008 -->
-<TITLE>
-ImportRewrite
-</TITLE>
-
-<META NAME="keywords" CONTENT="org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite class">
-
-<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../../stylesheet.css" TITLE="Style">
-
-<SCRIPT type="text/javascript">
-function windowTitle()
-{
- parent.document.title="ImportRewrite";
-}
-</SCRIPT>
-<NOSCRIPT>
-</NOSCRIPT>
-
-</HEAD>
-
-<BODY BGCOLOR="white" onload="windowTitle();">
-
-
-<!-- ========= START OF TOP NAVBAR ======= -->
-<A NAME="navbar_top"><!-- --></A>
-<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
-<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
-<TR>
-<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
-<A NAME="navbar_top_firstrow"><!-- --></A>
-<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
- <TR ALIGN="center" VALIGN="top">
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ImportRewrite.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
- </TR>
-</TABLE>
-</TD>
-<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
-</EM>
-</TD>
-</TR>
-
-<TR>
-<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
-&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ASTRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><B>PREV CLASS</B></A>&nbsp;
-&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><B>NEXT CLASS</B></A></FONT></TD>
-<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
- <A HREF="../../../../../../../index.html?org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" target="_top"><B>FRAMES</B></A> &nbsp;
-&nbsp;<A HREF="ImportRewrite.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
-&nbsp;<SCRIPT type="text/javascript">
- <!--
- if(window==top) {
- document.writeln('<A HREF="../../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
- }
- //-->
-</SCRIPT>
-<NOSCRIPT>
- <A HREF="../../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
-</NOSCRIPT>
-
-
-</FONT></TD>
-</TR>
-<TR>
-<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
- SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
-<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
-DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
-</TR>
-</TABLE>
-<A NAME="skip-navbar_top"></A>
-<!-- ========= END OF TOP NAVBAR ========= -->
-
-<HR>
-<!-- ======== START OF CLASS DATA ======== -->
-<H2>
-<FONT SIZE="-1">
-org.eclipse.wst.jsdt.core.dom.rewrite</FONT>
-<BR>
-Class ImportRewrite</H2>
-<PRE>
-java.lang.Object
- <IMG SRC="../../../../../../../resources/inherit.gif" ALT="extended by "><B>org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite</B>
-</PRE>
-<HR>
-<DL>
-<DT><PRE>public final class <B>ImportRewrite</B><DT>extends java.lang.Object</DL>
-</PRE>
-
-<P>
-The <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A> helps updating imports following a import order and on-demand imports threshold as configured by a project.
- <p>
- The import rewrite is created on a javaScript unit and collects references to types that are added or removed. When adding imports, e.g. using
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(java.lang.String)"><CODE>addImport(String)</CODE></A>, the import rewrite evaluates if the type can be imported and returns the a reference to the type that can be used in code.
- This reference is either unqualified if the import could be added, or fully qualified if the import failed due to a conflict with another element of the same name.
- </p>
- <p>
- On <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#rewriteImports(IProgressMonitor)"><CODE>rewriteImports(IProgressMonitor)</CODE></A> the rewrite translates these descriptions into
- text edits that can then be applied to the original source. The rewrite infrastructure tries to generate minimal text changes and only
- works on the import statements. It is possible to combine the result of an import rewrite with the result of a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ASTRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ASTRewrite</CODE></A>
- as long as no import statements are modified by the AST rewrite.
- </p>
- <p>The options controlling the import order and on-demand thresholds are:
- <ul><li><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setImportOrder(java.lang.String[])"><CODE>setImportOrder(String[])</CODE></A> specifies the import groups and their preferred order</li>
- <li><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setOnDemandImportThreshold(int)"><CODE>setOnDemandImportThreshold(int)</CODE></A> specifies the number of imports in a group needed for a on-demand import statement (star import)</li>
- <li><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setStaticOnDemandImportThreshold(int)"><CODE>setStaticOnDemandImportThreshold(int)</CODE></A> specifies the number of static imports in a group needed for a on-demand import statement (star import)</li>
-</ul>
- This class is not intended to be subclassed.
- </p>
-
- Provisional API: This class/interface is part of an interim API that is still under development and expected to
- change significantly before reaching stability. It is being made available at this early stage to solicit feedback
- from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken
- (repeatedly) as the API evolves.
-<P>
-
-<P>
-<HR>
-
-<P>
-<!-- ======== NESTED CLASS SUMMARY ======== -->
-
-<A NAME="nested_class_summary"><!-- --></A>
-<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
-<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
-<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
-<B>Nested Class Summary</B></FONT></TH>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>static&nbsp;class</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A></B></CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite.ImportRewriteContext</CODE></A> can optionally be used in e.g.</TD>
-</TR>
-</TABLE>
-&nbsp;
-<!-- ========== METHOD SUMMARY =========== -->
-
-<A NAME="method_summary"><!-- --></A>
-<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
-<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
-<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
-<B>Method Summary</B></FONT></TH>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding)">addImport</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding, org.eclipse.wst.jsdt.core.dom.AST)">addImport</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> that can be used
- in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding, org.eclipse.wst.jsdt.core.dom.AST, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)">addImport</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> that can be used
- in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)">addImport</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(java.lang.String)">addImport</A></B>(java.lang.String&nbsp;qualifiedTypeName)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImport(java.lang.String, java.lang.String, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)">addImport</A></B>(java.lang.String&nbsp;qualifiedTypeName,
- java.lang.String&nbsp;packageName,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImportFromSignature(java.lang.String, org.eclipse.wst.jsdt.core.dom.AST)">addImportFromSignature</A></B>(java.lang.String&nbsp;typeSig,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> node that can be used
- in the code as a reference to the type.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addImportFromSignature(java.lang.String, org.eclipse.wst.jsdt.core.dom.AST, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)">addImportFromSignature</A></B>(java.lang.String&nbsp;typeSig,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> node that can be used
- in the code as a reference to the type.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addStaticImport(org.eclipse.wst.jsdt.core.dom.IBinding)">addStaticImport</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/IBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">IBinding</A>&nbsp;binding)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new static import to the rewriter's record and returns a reference that can be used in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addStaticImport(org.eclipse.wst.jsdt.core.dom.IBinding, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)">addStaticImport</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/IBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">IBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new static import to the rewriter's record and returns a reference that can be used in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addStaticImport(java.lang.String, java.lang.String, boolean)">addStaticImport</A></B>(java.lang.String&nbsp;declaringTypeName,
- java.lang.String&nbsp;simpleName,
- boolean&nbsp;isField)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new static import to the rewriter's record and returns a reference that can be used in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#addStaticImport(java.lang.String, java.lang.String, boolean, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)">addStaticImport</A></B>(java.lang.String&nbsp;declaringTypeName,
- java.lang.String&nbsp;simpleName,
- boolean&nbsp;isField,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a new static import to the rewriter's record and returns a reference that can be used in the code.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>static&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#create(org.eclipse.wst.jsdt.core.IJavaScriptUnit, boolean)">create</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core">IJavaScriptUnit</A>&nbsp;cu,
- boolean&nbsp;restoreExistingImports)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A> from a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core"><CODE>IJavaScriptUnit</CODE></A>.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>static&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#create(org.eclipse.wst.jsdt.core.dom.JavaScriptUnit, boolean)">create</A></B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/JavaScriptUnit.html" title="class in org.eclipse.wst.jsdt.core.dom">JavaScriptUnit</A>&nbsp;astRoot,
- boolean&nbsp;restoreExistingImports)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A> from a an AST (<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/JavaScriptUnit.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>JavaScriptUnit</CODE></A>).</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String[]</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getAddedImports()">getAddedImports</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns all non-static imports that are recorded to be added.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String[]</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getAddedStaticImports()">getAddedStaticImports</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns all static imports that are recorded to be added.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core">IJavaScriptUnit</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getCompilationUnit()">getCompilationUnit</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The javaScript unit for which this import rewrite was created for.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String[]</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getCreatedImports()">getCreatedImports</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns all new non-static imports created by the last invocation of <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#rewriteImports(IProgressMonitor)"><CODE>rewriteImports(IProgressMonitor)</CODE></A>
- or <code>null</code> if these methods have not been called yet.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String[]</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getCreatedStaticImports()">getCreatedStaticImports</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns all new static imports created by the last invocation of <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#rewriteImports(IProgressMonitor)"><CODE>rewriteImports(IProgressMonitor)</CODE></A>
- or <code>null</code> if these methods have not been called yet.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A></CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getDefaultImportRewriteContext()">getDefaultImportRewriteContext</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the default rewrite context that only knows about the imported types.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String[]</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getRemovedImports()">getRemovedImports</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns all non-static imports that are recorded to be removed.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;java.lang.String[]</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getRemovedStaticImports()">getRemovedStaticImports</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns all static imports that are recorded to be removed.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;boolean</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#hasRecordedChanges()">hasRecordedChanges</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns <code>true</code> if imports have been recorded to be added or removed.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;boolean</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#isImportMatchesType()">isImportMatchesType</A></B>()</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;boolean</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#removeImport(java.lang.String)">removeImport</A></B>(java.lang.String&nbsp;qualifiedName)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Records to remove a import.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;boolean</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#removeStaticImport(java.lang.String)">removeStaticImport</A></B>(java.lang.String&nbsp;qualifiedName)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Records to remove a static import.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;TextEdit</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#rewriteImports(IProgressMonitor)">rewriteImports</A></B>(IProgressMonitor&nbsp;monitor)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts all modifications recorded by this rewriter into an object representing the corresponding text
- edits to the source code of the rewrite's javaScript unit.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;void</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setFilterImplicitImports(boolean)">setFilterImplicitImports</A></B>(boolean&nbsp;filterImplicitImports)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Specifies that implicit imports (types in default package, package <code>java.lang</code> or
- in the same package as the rewrite javaScript unit should not be created except if necessary
- to resolve an on-demand import conflict.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;void</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setImportOrder(java.lang.String[])">setImportOrder</A></B>(java.lang.String[]&nbsp;order)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Defines the import groups and order to be used by the <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A>.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;void</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setOnDemandImportThreshold(int)">setOnDemandImportThreshold</A></B>(int&nbsp;threshold)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the on-demand import threshold for normal (non-static) imports.</TD>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
-<CODE>&nbsp;void</CODE></FONT></TD>
-<TD><CODE><B><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#setStaticOnDemandImportThreshold(int)">setStaticOnDemandImportThreshold</A></B>(int&nbsp;threshold)</CODE>
-
-<BR>
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the on-demand import threshold for static imports.</TD>
-</TR>
-</TABLE>
-&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
-<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
-<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
-<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
-</TR>
-<TR BGCOLOR="white" CLASS="TableRowColor">
-<TD><CODE>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
-</TR>
-</TABLE>
-&nbsp;
-<P>
-
-<!-- ============ METHOD DETAIL ========== -->
-
-<A NAME="method_detail"><!-- --></A>
-<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
-<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
-<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
-<B>Method Detail</B></FONT></TH>
-</TR>
-</TABLE>
-
-<A NAME="create(org.eclipse.wst.jsdt.core.IJavaScriptUnit, boolean)"><!-- --></A><H3>
-create</H3>
-<PRE>
-public static <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite</A> <B>create</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core">IJavaScriptUnit</A>&nbsp;cu,
- boolean&nbsp;restoreExistingImports)
- throws <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/JavaScriptModelException.html" title="class in org.eclipse.wst.jsdt.core">JavaScriptModelException</A></PRE>
-<DL>
-<DD>Creates a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A> from a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core"><CODE>IJavaScriptUnit</CODE></A>. If <code>restoreExistingImports</code>
- is <code>true</code>, all existing imports are kept, and new imports will be inserted at best matching locations. If
- <code>restoreExistingImports</code> is <code>false</code>, the existing imports will be removed and only the
- newly added imports will be created.
- <p>
- Note that <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#create(org.eclipse.wst.jsdt.core.IJavaScriptUnit, boolean)"><CODE>create(IJavaScriptUnit, boolean)</CODE></A> is more efficient than this method if an AST for
- the javaScript unit is already available.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>cu</CODE> - the javaScript unit to create the imports for<DD><CODE>restoreExistingImports</CODE> - specifies if the existing imports should be kept or removed.
-<DT><B>Returns:</B><DD>the created import rewriter.
-<DT><B>Throws:</B>
-<DD><CODE><A HREF="../../../../../../../org/eclipse/wst/jsdt/core/JavaScriptModelException.html" title="class in org.eclipse.wst.jsdt.core">JavaScriptModelException</A></CODE> - thrown when the javaScript unit could not be accessed.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="create(org.eclipse.wst.jsdt.core.dom.JavaScriptUnit, boolean)"><!-- --></A><H3>
-create</H3>
-<PRE>
-public static <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite</A> <B>create</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/JavaScriptUnit.html" title="class in org.eclipse.wst.jsdt.core.dom">JavaScriptUnit</A>&nbsp;astRoot,
- boolean&nbsp;restoreExistingImports)</PRE>
-<DL>
-<DD>Creates a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A> from a an AST (<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/JavaScriptUnit.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>JavaScriptUnit</CODE></A>). The AST has to be created from a
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core"><CODE>IJavaScriptUnit</CODE></A>, that means <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ASTParser.html#setSource(org.eclipse.wst.jsdt.core.IJavaScriptUnit)"><CODE>ASTParser.setSource(IJavaScriptUnit)</CODE></A> has been used when creating the
- AST. If <code>restoreExistingImports</code> is <code>true</code>, all existing imports are kept, and new imports
- will be inserted at best matching locations. If <code>restoreExistingImports</code> is <code>false</code>, the
- existing imports will be removed and only the newly added imports will be created.
- <p>
- Note that this method is more efficient than using <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#create(org.eclipse.wst.jsdt.core.IJavaScriptUnit, boolean)"><CODE>create(IJavaScriptUnit, boolean)</CODE></A> if an AST is already available.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>astRoot</CODE> - the AST root node to create the imports for<DD><CODE>restoreExistingImports</CODE> - specifies if the existing imports should be kept or removed.
-<DT><B>Returns:</B><DD>the created import rewriter.
-<DT><B>Throws:</B>
-<DD><CODE>java.lang.IllegalArgumentException</CODE> - thrown when the passed AST is null or was not created from a javaScript unit.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="setImportOrder(java.lang.String[])"><!-- --></A><H3>
-setImportOrder</H3>
-<PRE>
-public void <B>setImportOrder</B>(java.lang.String[]&nbsp;order)</PRE>
-<DL>
-<DD>Defines the import groups and order to be used by the <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><CODE>ImportRewrite</CODE></A>.
- Imports are added to the group matching their qualified name most. The empty group name groups all imports not matching
- any other group. Static imports are managed in separate groups. Static import group names are prefixed with a '#' character.
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>order</CODE> - A list of strings defining the import groups. A group name must be a valid package name or empty. If can be
- prefixed by the '#' character for static import groups</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="setOnDemandImportThreshold(int)"><!-- --></A><H3>
-setOnDemandImportThreshold</H3>
-<PRE>
-public void <B>setOnDemandImportThreshold</B>(int&nbsp;threshold)</PRE>
-<DL>
-<DD>Sets the on-demand import threshold for normal (non-static) imports.
- This threshold defines the number of imports that need to be in a group to use
- a on-demand (star) import declaration instead.
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>threshold</CODE> - a positive number defining the on-demand import threshold
- for normal (non-static) imports.
-<DT><B>Throws:</B>
-<DD><CODE>java.lang.IllegalArgumentException</CODE> - a <CODE>IllegalArgumentException</CODE> is thrown
- if the number is not positive.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="setStaticOnDemandImportThreshold(int)"><!-- --></A><H3>
-setStaticOnDemandImportThreshold</H3>
-<PRE>
-public void <B>setStaticOnDemandImportThreshold</B>(int&nbsp;threshold)</PRE>
-<DL>
-<DD>Sets the on-demand import threshold for static imports.
- This threshold defines the number of imports that need to be in a group to use
- a on-demand (star) import declaration instead.
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>threshold</CODE> - a positive number defining the on-demand import threshold
- for normal (non-static) imports.
-<DT><B>Throws:</B>
-<DD><CODE>java.lang.IllegalArgumentException</CODE> - a <CODE>IllegalArgumentException</CODE> is thrown
- if the number is not positive.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getCompilationUnit()"><!-- --></A><H3>
-getCompilationUnit</H3>
-<PRE>
-public <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/IJavaScriptUnit.html" title="interface in org.eclipse.wst.jsdt.core">IJavaScriptUnit</A> <B>getCompilationUnit</B>()</PRE>
-<DL>
-<DD>The javaScript unit for which this import rewrite was created for.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the javaScript unit for which this import rewrite was created for.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getDefaultImportRewriteContext()"><!-- --></A><H3>
-getDefaultImportRewriteContext</H3>
-<PRE>
-public <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A> <B>getDefaultImportRewriteContext</B>()</PRE>
-<DL>
-<DD>Returns the default rewrite context that only knows about the imported types. Clients
- can write their own context and use the default context for the default behavior.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the default import rewrite context.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="setFilterImplicitImports(boolean)"><!-- --></A><H3>
-setFilterImplicitImports</H3>
-<PRE>
-public void <B>setFilterImplicitImports</B>(boolean&nbsp;filterImplicitImports)</PRE>
-<DL>
-<DD>Specifies that implicit imports (types in default package, package <code>java.lang</code> or
- in the same package as the rewrite javaScript unit should not be created except if necessary
- to resolve an on-demand import conflict. The filter is enabled by default.
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>filterImplicitImports</CODE> - if set, implicit imports will be filtered.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImportFromSignature(java.lang.String, org.eclipse.wst.jsdt.core.dom.AST)"><!-- --></A><H3>
-addImportFromSignature</H3>
-<PRE>
-public <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A> <B>addImportFromSignature</B>(java.lang.String&nbsp;typeSig,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> node that can be used
- in the code as a reference to the type. The type binding can be an array binding, type variable or wildcard.
- If the binding is a generic type, the type parameters are ignored. For parameterized types, also the type
- arguments are processed and imports added if necessary. Anonymous types inside type arguments are normalized to their base type, wildcard
- of wildcards are ignored.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>typeSig</CODE> - the signature of the type to be added.<DD><CODE>ast</CODE> - the AST to create the returned type for.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImportFromSignature(java.lang.String, org.eclipse.wst.jsdt.core.dom.AST, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)"><!-- --></A><H3>
-addImportFromSignature</H3>
-<PRE>
-public <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A> <B>addImportFromSignature</B>(java.lang.String&nbsp;typeSig,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> node that can be used
- in the code as a reference to the type. The type binding can be an array binding, type variable or wildcard.
- If the binding is a generic type, the type parameters are ignored. For parameterized types, also the type
- arguments are processed and imports added if necessary. Anonymous types inside type arguments are normalized to their base type, wildcard
- of wildcards are ignored.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>typeSig</CODE> - the signature of the type to be added.<DD><CODE>ast</CODE> - the AST to create the returned type for.<DD><CODE>context</CODE> - an optional context that knows about types visible in the current scope or <code>null</code>
- to use the default context only using the available imports.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding)"><!-- --></A><H3>
-addImport</H3>
-<PRE>
-public java.lang.String <B>addImport</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code. The type binding can be an array binding, type variable or wildcard.
- If the binding is a generic type, the type parameters are ignored. For parameterized types, also the type
- arguments are processed and imports added if necessary. Anonymous types inside type arguments are normalized to their base type, wildcard
- of wildcards are ignored.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>binding</CODE> - the signature of the type to be added.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)"><!-- --></A><H3>
-addImport</H3>
-<PRE>
-public java.lang.String <B>addImport</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code. The type binding can be an array binding, type variable or wildcard.
- If the binding is a generic type, the type parameters are ignored. For parameterized types, also the type
- arguments are processed and imports added if necessary. Anonymous types inside type arguments are normalized to their base type, wildcard
- of wildcards are ignored.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>binding</CODE> - the signature of the type to be added.<DD><CODE>context</CODE> - an optional context that knows about types visible in the current scope or <code>null</code>
- to use the default context only using the available imports.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding, org.eclipse.wst.jsdt.core.dom.AST)"><!-- --></A><H3>
-addImport</H3>
-<PRE>
-public <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A> <B>addImport</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> that can be used
- in the code. The type binding can be an array binding, type variable or wildcard.
- If the binding is a generic type, the type parameters are ignored. For parameterized types, also the type
- arguments are processed and imports added if necessary. Anonymous types inside type arguments are normalized to their base type, wildcard
- of wildcards are ignored.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>binding</CODE> - the signature of the type to be added.<DD><CODE>ast</CODE> - the AST to create the returned type for.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImport(org.eclipse.wst.jsdt.core.dom.ITypeBinding, org.eclipse.wst.jsdt.core.dom.AST, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)"><!-- --></A><H3>
-addImport</H3>
-<PRE>
-public <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom">Type</A> <B>addImport</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/ITypeBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">ITypeBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/AST.html" title="class in org.eclipse.wst.jsdt.core.dom">AST</A>&nbsp;ast,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/Type.html" title="class in org.eclipse.wst.jsdt.core.dom"><CODE>Type</CODE></A> that can be used
- in the code. The type binding can be an array binding, type variable or wildcard.
- If the binding is a generic type, the type parameters are ignored. For parameterized types, also the type
- arguments are processed and imports added if necessary. Anonymous types inside type arguments are normalized to their base type, wildcard
- of wildcards are ignored.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>binding</CODE> - the signature of the type to be added.<DD><CODE>ast</CODE> - the AST to create the returned type for.<DD><CODE>context</CODE> - an optional context that knows about types visible in the current scope or <code>null</code>
- to use the default context only using the available imports.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImport(java.lang.String, java.lang.String, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)"><!-- --></A><H3>
-addImport</H3>
-<PRE>
-public java.lang.String <B>addImport</B>(java.lang.String&nbsp;qualifiedTypeName,
- java.lang.String&nbsp;packageName,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code. The type binding can only be an array or non-generic type.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>qualifiedTypeName</CODE> - the qualified type name of the type to be added<DD><CODE>context</CODE> - an optional context that knows about types visible in the current scope or <code>null</code>
- to use the default context only using the available imports.
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addImport(java.lang.String)"><!-- --></A><H3>
-addImport</H3>
-<PRE>
-public java.lang.String <B>addImport</B>(java.lang.String&nbsp;qualifiedTypeName)</PRE>
-<DL>
-<DD>Adds a new import to the rewriter's record and returns a type reference that can be used
- in the code. The type binding can only be an array or non-generic type.
- <p>
- No imports are added for types that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>qualifiedTypeName</CODE> - the qualified type name of the type to be added
-<DT><B>Returns:</B><DD>returns a type to which the type binding can be assigned to. The returned type contains is unqualified
- when an import could be added or was already known. It is fully qualified, if an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addStaticImport(org.eclipse.wst.jsdt.core.dom.IBinding)"><!-- --></A><H3>
-addStaticImport</H3>
-<PRE>
-public java.lang.String <B>addStaticImport</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/IBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">IBinding</A>&nbsp;binding)</PRE>
-<DL>
-<DD>Adds a new static import to the rewriter's record and returns a reference that can be used in the code. The reference will
- be fully qualified if an import conflict prevented the import or unqualified if the import succeeded or was already
- existing.
- <p>
- No imports are added for members that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>binding</CODE> - The binding of the static field or method to be added.
-<DT><B>Returns:</B><DD>returns either the simple member name if the import was successful or else the qualified name if
- an import conflict prevented the import.
-<DT><B>Throws:</B>
-<DD><CODE>java.lang.IllegalArgumentException</CODE> - an <CODE>IllegalArgumentException</CODE> is thrown if the binding is not a static field
- or method.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addStaticImport(org.eclipse.wst.jsdt.core.dom.IBinding, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)"><!-- --></A><H3>
-addStaticImport</H3>
-<PRE>
-public java.lang.String <B>addStaticImport</B>(<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/IBinding.html" title="interface in org.eclipse.wst.jsdt.core.dom">IBinding</A>&nbsp;binding,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</PRE>
-<DL>
-<DD>Adds a new static import to the rewriter's record and returns a reference that can be used in the code. The reference will
- be fully qualified if an import conflict prevented the import or unqualified if the import succeeded or was already
- existing.
- <p>
- No imports are added for members that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>binding</CODE> - The binding of the static field or method to be added.<DD><CODE>context</CODE> - an optional context that knows about members visible in the current scope or <code>null</code>
- to use the default context only using the available imports.
-<DT><B>Returns:</B><DD>returns either the simple member name if the import was successful or else the qualified name if
- an import conflict prevented the import.
-<DT><B>Throws:</B>
-<DD><CODE>java.lang.IllegalArgumentException</CODE> - an <CODE>IllegalArgumentException</CODE> is thrown if the binding is not a static field
- or method.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addStaticImport(java.lang.String, java.lang.String, boolean)"><!-- --></A><H3>
-addStaticImport</H3>
-<PRE>
-public java.lang.String <B>addStaticImport</B>(java.lang.String&nbsp;declaringTypeName,
- java.lang.String&nbsp;simpleName,
- boolean&nbsp;isField)</PRE>
-<DL>
-<DD>Adds a new static import to the rewriter's record and returns a reference that can be used in the code. The reference will
- be fully qualified if an import conflict prevented the import or unqualified if the import succeeded or was already
- existing.
- <p>
- No imports are added for members that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>declaringTypeName</CODE> - The qualified name of the static's member declaring type<DD><CODE>simpleName</CODE> - the simple name of the member; either a field or a method name.<DD><CODE>isField</CODE> - <code>true</code> specifies that the member is a field, <code>false</code> if it is a
- method.
-<DT><B>Returns:</B><DD>returns either the simple member name if the import was successful or else the qualified name if
- an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="addStaticImport(java.lang.String, java.lang.String, boolean, org.eclipse.wst.jsdt.core.dom.rewrite.ImportRewrite.ImportRewriteContext)"><!-- --></A><H3>
-addStaticImport</H3>
-<PRE>
-public java.lang.String <B>addStaticImport</B>(java.lang.String&nbsp;declaringTypeName,
- java.lang.String&nbsp;simpleName,
- boolean&nbsp;isField,
- <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite">ImportRewrite.ImportRewriteContext</A>&nbsp;context)</PRE>
-<DL>
-<DD>Adds a new static import to the rewriter's record and returns a reference that can be used in the code. The reference will
- be fully qualified if an import conflict prevented the import or unqualified if the import succeeded or was already
- existing.
- <p>
- No imports are added for members that are already known. If a import for a type is recorded to be removed, this record is discarded instead.
- </p>
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been added.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>declaringTypeName</CODE> - The qualified name of the static's member declaring type<DD><CODE>simpleName</CODE> - the simple name of the member; either a field or a method name.<DD><CODE>isField</CODE> - <code>true</code> specifies that the member is a field, <code>false</code> if it is a
- method.<DD><CODE>context</CODE> - an optional context that knows about members visible in the current scope or <code>null</code>
- to use the default context only using the available imports.
-<DT><B>Returns:</B><DD>returns either the simple member name if the import was successful or else the qualified name if
- an import conflict prevented the import.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="removeImport(java.lang.String)"><!-- --></A><H3>
-removeImport</H3>
-<PRE>
-public boolean <B>removeImport</B>(java.lang.String&nbsp;qualifiedName)</PRE>
-<DL>
-<DD>Records to remove a import. No remove is recorded if no such import exists or if such an import is recorded
- to be added. In that case the record of the addition is discarded.
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that an import has been removed.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>qualifiedName</CODE> - The import name to remove.
-<DT><B>Returns:</B><DD><code>true</code> is returned of an import of the given name could be found.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="removeStaticImport(java.lang.String)"><!-- --></A><H3>
-removeStaticImport</H3>
-<PRE>
-public boolean <B>removeStaticImport</B>(java.lang.String&nbsp;qualifiedName)</PRE>
-<DL>
-<DD>Records to remove a static import. No remove is recorded if no such import exists or if such an import is recorded
- to be added. In that case the record of the addition is discarded.
- <p>
- The content of the javaScript unit itself is actually not modified
- in any way by this method; rather, the rewriter just records that a new import has been removed.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>qualifiedName</CODE> - The import name to remove.
-<DT><B>Returns:</B><DD><code>true</code> is returned of an import of the given name could be found.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="rewriteImports(IProgressMonitor)"><!-- --></A><H3>
-rewriteImports</H3>
-<PRE>
-public final TextEdit <B>rewriteImports</B>(IProgressMonitor&nbsp;monitor)
- throws CoreException</PRE>
-<DL>
-<DD>Converts all modifications recorded by this rewriter into an object representing the corresponding text
- edits to the source code of the rewrite's javaScript unit. The javaScript unit itself is not modified.
- <p>
- Calling this methods does not discard the modifications on record. Subsequence modifications are added
- to the ones already on record. If this method is called again later, the resulting text edit object will accurately
- reflect the net cumulative affect of all those changes.
- </p>
-<P>
-<DD><DL>
-<DT><B>Parameters:</B><DD><CODE>monitor</CODE> - the progress monitor or <code>null</code>
-<DT><B>Returns:</B><DD>text edit object describing the changes to the document corresponding to the changes
- recorded by this rewriter
-<DT><B>Throws:</B>
-<DD><CODE>CoreException</CODE> - the exception is thrown if the rewrite fails.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getCreatedImports()"><!-- --></A><H3>
-getCreatedImports</H3>
-<PRE>
-public java.lang.String[] <B>getCreatedImports</B>()</PRE>
-<DL>
-<DD>Returns all new non-static imports created by the last invocation of <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#rewriteImports(IProgressMonitor)"><CODE>rewriteImports(IProgressMonitor)</CODE></A>
- or <code>null</code> if these methods have not been called yet.
- <p>
- Note that this list doesn't need to be the same as the added imports (see <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getAddedImports()"><CODE>getAddedImports()</CODE></A>) as
- implicit imports are not created and some imports are represented by on-demand imports instead.
- </p>
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the created imports</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getCreatedStaticImports()"><!-- --></A><H3>
-getCreatedStaticImports</H3>
-<PRE>
-public java.lang.String[] <B>getCreatedStaticImports</B>()</PRE>
-<DL>
-<DD>Returns all new static imports created by the last invocation of <A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#rewriteImports(IProgressMonitor)"><CODE>rewriteImports(IProgressMonitor)</CODE></A>
- or <code>null</code> if these methods have not been called yet.
- <p>
- Note that this list doesn't need to be the same as the added static imports (<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html#getAddedStaticImports()"><CODE>getAddedStaticImports()</CODE></A>) as
- implicit imports are not created and some imports are represented by on-demand imports instead.
- </p
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the created imports</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getAddedImports()"><!-- --></A><H3>
-getAddedImports</H3>
-<PRE>
-public java.lang.String[] <B>getAddedImports</B>()</PRE>
-<DL>
-<DD>Returns all non-static imports that are recorded to be added.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the imports recorded to be added.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getAddedStaticImports()"><!-- --></A><H3>
-getAddedStaticImports</H3>
-<PRE>
-public java.lang.String[] <B>getAddedStaticImports</B>()</PRE>
-<DL>
-<DD>Returns all static imports that are recorded to be added.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the static imports recorded to be added.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getRemovedImports()"><!-- --></A><H3>
-getRemovedImports</H3>
-<PRE>
-public java.lang.String[] <B>getRemovedImports</B>()</PRE>
-<DL>
-<DD>Returns all non-static imports that are recorded to be removed.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the imports recorded to be removed.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="getRemovedStaticImports()"><!-- --></A><H3>
-getRemovedStaticImports</H3>
-<PRE>
-public java.lang.String[] <B>getRemovedStaticImports</B>()</PRE>
-<DL>
-<DD>Returns all static imports that are recorded to be removed.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>the static imports recorded to be removed.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="hasRecordedChanges()"><!-- --></A><H3>
-hasRecordedChanges</H3>
-<PRE>
-public boolean <B>hasRecordedChanges</B>()</PRE>
-<DL>
-<DD>Returns <code>true</code> if imports have been recorded to be added or removed.
-<P>
-<DD><DL>
-
-<DT><B>Returns:</B><DD>boolean returns if any changes to imports have been recorded.</DL>
-</DD>
-</DL>
-<HR>
-
-<A NAME="isImportMatchesType()"><!-- --></A><H3>
-isImportMatchesType</H3>
-<PRE>
-public boolean <B>isImportMatchesType</B>()</PRE>
-<DL>
-<DD><DL>
-</DL>
-</DD>
-</DL>
-<!-- ========= END OF CLASS DATA ========= -->
-<HR>
-
-
-<!-- ======= START OF BOTTOM NAVBAR ====== -->
-<A NAME="navbar_bottom"><!-- --></A>
-<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
-<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
-<TR>
-<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
-<A NAME="navbar_bottom_firstrow"><!-- --></A>
-<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
- <TR ALIGN="center" VALIGN="top">
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ImportRewrite.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
- <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
- </TR>
-</TABLE>
-</TD>
-<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
-</EM>
-</TD>
-</TR>
-
-<TR>
-<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
-&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ASTRewrite.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><B>PREV CLASS</B></A>&nbsp;
-&nbsp;<A HREF="../../../../../../../org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.ImportRewriteContext.html" title="class in org.eclipse.wst.jsdt.core.dom.rewrite"><B>NEXT CLASS</B></A></FONT></TD>
-<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
- <A HREF="../../../../../../../index.html?org/eclipse/wst/jsdt/core/dom/rewrite/ImportRewrite.html" target="_top"><B>FRAMES</B></A> &nbsp;
-&nbsp;<A HREF="ImportRewrite.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
-&nbsp;<SCRIPT type="text/javascript">
- <!--
- if(window==top) {
- document.writeln('<A HREF="../../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
- }
- //-->
-</SCRIPT>
-<NOSCRIPT>
- <A HREF="../../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
-</NOSCRIPT>
-
-
-</FONT></TD>
-</TR>
-<TR>
-<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
- SUMMARY:&nbsp;<A HREF="#nested_class_summary">NESTED</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
-<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
-DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
-</TR>
-</TABLE>
-<A NAME="skip-navbar_bottom"></A>
-<!-- ======== END OF BOTTOM NAVBAR ======= -->
-
-<HR>
-
-</BODY>
-</HTML>

Back to the top