本文整理了Java中org.eclipse.jdt.core.dom.CompilationUnit.equals()
方法的一些代码示例,展示了CompilationUnit.equals()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。CompilationUnit.equals()
方法的具体详情如下:
包路径:org.eclipse.jdt.core.dom.CompilationUnit
类名称:CompilationUnit
方法名:equals
暂无
代码示例来源:origin: forge/roaster
return false;
else if (!unit.equals(other.unit))
return false;
return true;
代码示例来源:origin: org.jboss.forge/roaster-jdt
return false;
else if (!unit.equals(other.unit))
return false;
return true;
代码示例来源:origin: org.jboss.forge/roaster-jdt
return false;
else if (!unit.equals(other.unit))
return false;
return true;
代码示例来源:origin: org.eclipse/org.eclipse.jdt.ui
/**
* Returns an AST for the given compilation unit handle.<br>
* If this is the unit containing the selection or the unit in which the factory
* is to reside, checks the appropriate field (<code>fCU</code> or <code>fFactoryCU</code>,
* respectively) and initializes the field with a new AST only if not already done.
*/
private CompilationUnit getASTFor(ICompilationUnit unitHandle) {
if (unitHandle.equals(fCUHandle)) { // is this the unit containing the selection?
if (fCU == null) {
fCU= ASTCreator.createAST(unitHandle, null);
if (fCU.equals(fFactoryUnitHandle)) // if selection unit and factory unit are the same...
fFactoryCU= fCU; // ...make sure the factory unit gets initialized
}
return fCU;
} else if (unitHandle.equals(fFactoryUnitHandle)) { // is this the "factory unit"?
if (fFactoryCU == null)
fFactoryCU= ASTCreator.createAST(unitHandle, null);
return fFactoryCU;
} else
return ASTCreator.createAST(unitHandle, null);
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jdt.ui
/**
* @param unitHandle
* @return an AST for the given compilation unit handle.<br>
* If this is the unit containing the selection or the unit in which the factory
* is to reside, checks the appropriate field (<code>fCU</code> or <code>fFactoryCU</code>,
* respectively) and initializes the field with a new AST only if not already done.
*/
private CompilationUnit getASTFor(ICompilationUnit unitHandle) {
if (unitHandle.equals(fCUHandle)) { // is this the unit containing the selection?
if (fCU == null) {
fCU= ASTCreator.createAST(unitHandle, null);
if (fCU.equals(fFactoryUnitHandle)) // if selection unit and factory unit are the same...
fFactoryCU= fCU; // ...make sure the factory unit gets initialized
}
return fCU;
} else if (unitHandle.equals(fFactoryUnitHandle)) { // is this the "factory unit"?
if (fFactoryCU == null)
fFactoryCU= ASTCreator.createAST(unitHandle, null);
return fFactoryCU;
} else
return ASTCreator.createAST(unitHandle, null);
}
内容来源于网络,如有侵权,请联系作者删除!