本文整理了Java中org.openide.filesystems.FileUtil.assertDeprecatedMethod()
方法的一些代码示例,展示了FileUtil.assertDeprecatedMethod()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。FileUtil.assertDeprecatedMethod()
方法的具体详情如下:
包路径:org.openide.filesystems.FileUtil
类名称:FileUtil
方法名:assertDeprecatedMethod
暂无
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/**
* @param fs filesystem that caused the error
*/
public EnvironmentNotSupportedException (FileSystem fs) {
this.fs = fs;
assert FileUtil.assertDeprecatedMethod();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/**
* @param fs filesystem that caused the error
* @param reason text description for the error
*/
public EnvironmentNotSupportedException (FileSystem fs, String reason) {
super (reason);
this.fs = fs;
assert FileUtil.assertDeprecatedMethod();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/**
* @param fs filesystem that caused the error
*/
public EnvironmentNotSupportedException (FileSystem fs) {
this.fs = fs;
assert FileUtil.assertDeprecatedMethod();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/**
* @param fs filesystem that caused the error
* @param reason text description for the error
*/
public EnvironmentNotSupportedException (FileSystem fs, String reason) {
super (reason);
this.fs = fs;
assert FileUtil.assertDeprecatedMethod();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
public FileSystemCapability() {
if (DOC == null) {
// do not report static initializers
return;
}
assert FileUtil.assertDeprecatedMethod();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
public FileSystemCapability() {
if (DOC == null) {
// do not report static initializers
return;
}
assert FileUtil.assertDeprecatedMethod();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
public Environment() {
assert FileUtil.assertDeprecatedMethod();
}
/** Adds one element to the class path environment variable.
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
public Environment() {
assert FileUtil.assertDeprecatedMethod();
}
/** Adds one element to the class path environment variable.
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/** Searches for the given resource among all filesystems, returning all matches.
* @param name name of the resource
* @return enumeration of {@link FileObject}s
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final Enumeration findAllResources(String name) {
assert FileUtil.assertDeprecatedMethod();
Vector v = new Vector(8);
Enumeration en = getFileSystems ();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.findResource(name);
if (fo != null) {
v.addElement(fo);
}
}
return v.elements();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/** Searches for the given resource among all filesystems, returning all matches.
* @param name name of the resource
* @return enumeration of {@link FileObject}s
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final Enumeration findAllResources(String name) {
assert FileUtil.assertDeprecatedMethod();
Vector v = new Vector(8);
Enumeration en = getFileSystems ();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.findResource(name);
if (fo != null) {
v.addElement(fo);
}
}
return v.elements();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/** Searches for the given resource among all filesystems.
* @see FileSystem#findResource
* @param name a name of the resource
* @return file object or <code>null</code> if the resource can not be found
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final FileObject findResource(String name) {
assert FileUtil.assertDeprecatedMethod();
Enumeration en = getFileSystems ();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.findResource(name);
if (fo != null) {
// object found
return fo;
}
}
return null;
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/** Finds all files among all filesystems matching a given name, returning all matches.
* All filesystems are queried with {@link FileSystem#find}.
*
* @param aPackage package name where each package is separated by a dot
* @param name name of the file (without dots) or <CODE>null</CODE> if
* one wants to obtain the name of a package and not a file in it
* @param ext extension of the file or <CODE>null</CODE> if one needs
* a package and not a file name
*
* @return enumeration of {@link FileObject}s
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final Enumeration findAll (String aPackage, String name, String ext) {
assert FileUtil.assertDeprecatedMethod();
Enumeration en = getFileSystems ();
Vector ret = new Vector();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.find (aPackage, name, ext);
if (fo != null) {
ret.addElement(fo);
}
}
return ret.elements();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/** Searches for the given resource among all filesystems.
* @see FileSystem#findResource
* @param name a name of the resource
* @return file object or <code>null</code> if the resource can not be found
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final FileObject findResource(String name) {
assert FileUtil.assertDeprecatedMethod();
Enumeration en = getFileSystems ();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.findResource(name);
if (fo != null) {
// object found
return fo;
}
}
return null;
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/** Finds all files among all filesystems matching a given name, returning all matches.
* All filesystems are queried with {@link FileSystem#find}.
*
* @param aPackage package name where each package is separated by a dot
* @param name name of the file (without dots) or <CODE>null</CODE> if
* one wants to obtain the name of a package and not a file in it
* @param ext extension of the file or <CODE>null</CODE> if one needs
* a package and not a file name
*
* @return enumeration of {@link FileObject}s
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final Enumeration findAll (String aPackage, String name, String ext) {
assert FileUtil.assertDeprecatedMethod();
Enumeration en = getFileSystems ();
Vector ret = new Vector();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.find (aPackage, name, ext);
if (fo != null) {
ret.addElement(fo);
}
}
return ret.elements();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/** Finds file when its name is provided. It scans in the list of
* filesystems and asks them for the specified file by a call to
* {@link FileSystem#find find}. The first object that is found is returned or <CODE>null</CODE>
* if none of the filesystems contain such a file.
*
* @param aPackage package name where each package is separated by a dot
* @param name name of the file (without dots) or <CODE>null</CODE> if
* one wants to obtain the name of a package and not a file in it
* @param ext extension of the file or <CODE>null</CODE> if one needs
* a package and not a file name
*
* @return {@link FileObject} that represents file with given name or
* <CODE>null</CODE> if the file does not exist
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final FileObject find (String aPackage, String name, String ext) {
assert FileUtil.assertDeprecatedMethod();
Enumeration en = getFileSystems ();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.find (aPackage, name, ext);
if (fo != null) {
// object found
return fo;
}
}
return null;
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/** Finds file when its name is provided. It scans in the list of
* filesystems and asks them for the specified file by a call to
* {@link FileSystem#find find}. The first object that is found is returned or <CODE>null</CODE>
* if none of the filesystems contain such a file.
*
* @param aPackage package name where each package is separated by a dot
* @param name name of the file (without dots) or <CODE>null</CODE> if
* one wants to obtain the name of a package and not a file in it
* @param ext extension of the file or <CODE>null</CODE> if one needs
* a package and not a file name
*
* @return {@link FileObject} that represents file with given name or
* <CODE>null</CODE> if the file does not exist
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public final FileObject find (String aPackage, String name, String ext) {
assert FileUtil.assertDeprecatedMethod();
Enumeration en = getFileSystems ();
while (en.hasMoreElements ()) {
FileSystem fs = (FileSystem)en.nextElement ();
FileObject fo = fs.find (aPackage, name, ext);
if (fo != null) {
// object found
return fo;
}
}
return null;
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/** Get fully-qualified filename. Does so by walking through all folders
* to the root of the filesystem. Separates files with provided <code>separatorChar</code>.
* The extension, if present, is separated from the basename with <code>extSepChar</code>.
* <p><strong>Note:</strong> <samp>fo.getPath()</samp> will have the
* same effect as using this method with <samp>/</samp> and <samp>.</samp> (the standard
* path and extension delimiters).
* @param separatorChar char to separate folders and files
* @param extSepChar char to separate extension
* @return the fully-qualified filename
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public String getPackageNameExt (char separatorChar, char extSepChar) {
assert FileUtil.assertDeprecatedMethod();
StringBuffer sb = new StringBuffer ();
if (isRoot () || getParent ().isRoot ()) return getNameExt ();
getParent ().constructName (sb, separatorChar);
String ext = getExt ();
if (ext == null || ext.equals ("")) // NOI18N
sb.append (separatorChar).append (getNameExt ());
else
sb.append (separatorChar).append (getName ()).append (extSepChar).append (getExt ());
return sb.toString();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/** Get fully-qualified filename. Does so by walking through all folders
* to the root of the filesystem. Separates files with provided <code>separatorChar</code>.
* The extension, if present, is separated from the basename with <code>extSepChar</code>.
* <p><strong>Note:</strong> <samp>fo.getPath()</samp> will have the
* same effect as using this method with <samp>/</samp> and <samp>.</samp> (the standard
* path and extension delimiters).
* @param separatorChar char to separate folders and files
* @param extSepChar char to separate extension
* @return the fully-qualified filename
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public String getPackageNameExt (char separatorChar, char extSepChar) {
assert FileUtil.assertDeprecatedMethod();
StringBuffer sb = new StringBuffer ();
if (isRoot () || getParent ().isRoot ()) return getNameExt ();
getParent ().constructName (sb, separatorChar);
String ext = getExt ();
if (ext == null || ext.equals ("")) // NOI18N
sb.append (separatorChar).append (getNameExt ());
else
sb.append (separatorChar).append (getName ()).append (extSepChar).append (getExt ());
return sb.toString();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide
/** Get fully-qualified filename, but without extension.
* Like {@link #getPackageNameExt} but omits the extension.
* @param separatorChar char to separate folders and files
* @return the fully-qualified filename
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public String getPackageName (char separatorChar) {
assert FileUtil.assertDeprecatedMethod();
StringBuffer sb = new StringBuffer ();
if (isRoot () || getParent ().isRoot ())
return (isFolder ()) ? getNameExt() : getName ();
getParent ().constructName (sb, separatorChar);
//sb.append (separatorChar).append ((isFolder ()) ? getNameExt() : getName ());
sb.append (separatorChar).append (getName ());
return sb.toString ();
}
代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide
/** Get fully-qualified filename, but without extension.
* Like {@link #getPackageNameExt} but omits the extension.
* @param separatorChar char to separate folders and files
* @return the fully-qualified filename
* @deprecated Please use the <a href="@JAVA/API@/org/netbeans/api/java/classpath/api.html">ClassPath API</a> instead.
*/
public String getPackageName (char separatorChar) {
assert FileUtil.assertDeprecatedMethod();
StringBuffer sb = new StringBuffer ();
if (isRoot () || getParent ().isRoot ())
return (isFolder ()) ? getNameExt() : getName ();
getParent ().constructName (sb, separatorChar);
//sb.append (separatorChar).append ((isFolder ()) ? getNameExt() : getName ());
sb.append (separatorChar).append (getName ());
return sb.toString ();
}
内容来源于网络,如有侵权,请联系作者删除!