本文整理匯總了Java中org.eclipse.core.runtime.Path.SEPARATOR屬性的典型用法代碼示例。如果您正苦於以下問題:Java Path.SEPARATOR屬性的具體用法?Java Path.SEPARATOR怎麽用?Java Path.SEPARATOR使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類org.eclipse.core.runtime.Path
的用法示例。
在下文中一共展示了Path.SEPARATOR屬性的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: computeXPath
private void computeXPath(Node node,XPathGridRow xPathGridRow,String computedXpath,List<GridRow> schemaRecords,String loopXPathQuery) {
org.w3c.dom.NodeList nodeList=node.getChildNodes();
if(!hasChild(node)){
xPathGridRow.setXPath(computedXpath+node.getNodeName());
if(StringUtils.isNotBlank(loopXPathQuery)){
xPathGridRow.setAbsolutexPath(loopXPathQuery+Path.SEPARATOR+xPathGridRow.getXPath());
}else{
xPathGridRow.setAbsolutexPath(xPathGridRow.getXPath());
}
schemaRecords.add(xPathGridRow);
}else{
computedXpath=computedXpath+node.getNodeName()+Path.SEPARATOR;
for(int i=0;i<nodeList.getLength();i++){
Node nod = nodeList.item(i);
if(nod.getNodeType()==Node.ELEMENT_NODE){
XPathGridRow xPathGridRowChild=new XPathGridRow();
String fieldName=nod.getNodeName();
if(fieldName.contains(":")){
fieldName=fieldName.split(":")[1];
}
xPathGridRowChild.setFieldName(fieldName);
addDataTypeToGridRow(nod,xPathGridRowChild);
xPathGridRowChild.setDateFormat("");
xPathGridRowChild.setPrecision("");
xPathGridRowChild.setScale("");
xPathGridRowChild.setScaleType(Integer.valueOf(Constants.DEFAULT_INDEX_VALUE_FOR_COMBOBOX));
xPathGridRowChild.setDescription("");
computeXPath(nod,xPathGridRowChild,computedXpath,schemaRecords,loopXPathQuery);
}
}
}
}
示例2: getAbsolutePath
private String getAbsolutePath(IJavaProject jProject, String packageName) {
try {
return JavaRuntime.computeDefaultRuntimeClassPath(jProject)[0]
+ (Path.SEPARATOR + packageName.replace(".", "/") + Path.SEPARATOR);
} catch (CoreException e) {
e.printStackTrace();
throw new RuntimeException(e);
}
}
示例3: makeXPathAbsoluteIfNot
private Path makeXPathAbsoluteIfNot(String xPath,String loopXPathQuery){
if(StringUtils.isNotBlank(loopXPathQuery) && !xPath.startsWith(loopXPathQuery)){
xPath=loopXPathQuery+Path.SEPARATOR+xPath;
}
return new Path(xPath);
}