本文整理了Java中jnr.posix.POSIX.lstat()
方法的一些代码示例,展示了POSIX.lstat()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。POSIX.lstat()
方法的具体详情如下:
包路径:jnr.posix.POSIX
类名称:POSIX
方法名:lstat
暂无
代码示例来源:origin: com.github.jnr/jnr-posix
public FileStat lstat(String path) {
try { return posix.lstat(path); } catch (UnsatisfiedLinkError ule) { return unimplementedNull(); }
}
代码示例来源:origin: com.github.jnr/jnr-posix
public int lstat(String path, FileStat stat) {
return posix().lstat(path, stat);
}
代码示例来源:origin: com.facebook.presto.cassandra/cassandra-driver
public int lstat(String path, FileStat stat) {
try { return posix.lstat(path, stat); } catch (UnsatisfiedLinkError ule) { return unimplementedInt(); }
}
代码示例来源:origin: com.facebook.presto.cassandra/cassandra-driver
public int lstat(String path, FileStat stat) {
return posix().lstat(path, stat);
}
代码示例来源:origin: com.github.jnr/jnr-posix
public FileStat lstat(String path) {
return posix().lstat(path);
}
代码示例来源:origin: com.facebook.presto.cassandra/cassandra-driver
public FileStat lstat(String path) {
try { return posix.lstat(path); } catch (UnsatisfiedLinkError ule) { return unimplementedNull(); }
}
代码示例来源:origin: io.prestosql.cassandra/cassandra-driver
public int lstat(String path, FileStat stat) {
return posix().lstat(path, stat);
}
代码示例来源:origin: com.cloudbees.util/jnr-unixsocket-nodep
public int lstat(String path, FileStat stat) {
return posix().lstat(path, stat);
}
代码示例来源:origin: com.github.jnr/jnr-posix
public int lstat(String path, FileStat stat) {
try { return posix.lstat(path, stat); } catch (UnsatisfiedLinkError ule) { return unimplementedInt(); }
}
代码示例来源:origin: com.facebook.presto.cassandra/cassandra-driver
public FileStat lstat(String path) {
return posix().lstat(path);
}
代码示例来源:origin: io.prestosql.cassandra/cassandra-driver
public int lstat(String path, FileStat stat) {
try { return posix.lstat(path, stat); } catch (UnsatisfiedLinkError ule) { return unimplementedInt(); }
}
代码示例来源:origin: io.prestosql.cassandra/cassandra-driver
public FileStat lstat(String path) {
return posix().lstat(path);
}
代码示例来源:origin: com.cloudbees.util/jnr-unixsocket-nodep
public int lstat(String path, FileStat stat) {
try { return posix.lstat(path, stat); } catch (UnsatisfiedLinkError ule) { return unimplementedInt(); }
}
代码示例来源:origin: org.kill-bill.billing/killbill-osgi-bundles-jruby
@Override
public FileStat lstat(POSIX posix) {
return posix.lstat(absolutePath());
}
代码示例来源:origin: io.prestosql.cassandra/cassandra-driver
public FileStat lstat(String path) {
try { return posix.lstat(path); } catch (UnsatisfiedLinkError ule) { return unimplementedNull(); }
}
代码示例来源:origin: com.cloudbees.util/jnr-unixsocket-nodep
public FileStat lstat(String path) {
try { return posix.lstat(path); } catch (UnsatisfiedLinkError ule) { return unimplementedNull(); }
}
代码示例来源:origin: org.jruby/jruby-complete
@Override
public FileStat lstat() {
FileStat stat = posix.allocateStat();
return posix.lstat(file.getAbsolutePath(), stat) < 0 ? null : stat;
}
代码示例来源:origin: org.jruby/jruby-core
@Override
public FileStat lstat() {
FileStat stat = posix.allocateStat();
return posix.lstat(file.getAbsolutePath(), stat) < 0 ? null : stat;
}
代码示例来源:origin: org.kill-bill.billing/killbill-osgi-bundles-jruby
@Override
public boolean isSymLink() {
try {
return symlinkPosix.lstat(absolutePath()).isSymlink();
} catch (Throwable t) {
return false;
}
}
代码示例来源:origin: com.ning.billing/killbill-osgi-bundles-jruby
@JRubyMethod(name = "symlink?", required = 1, module = true)
public static RubyBoolean symlink_p(IRubyObject recv, IRubyObject filename) {
Ruby runtime = recv.getRuntime();
JRubyFile file = file(filename);
try {
// Note: We can't use file.exists() to check whether the symlink
// exists or not, because that method returns false for existing
// but broken symlink. So, we try without the existence check,
// but in the try-catch block.
// MRI behavior: symlink? on broken symlink should return true.
return runtime.newBoolean(runtime.getPosix().lstat(file.getAbsolutePath()).isSymlink());
} catch (SecurityException re) {
return runtime.getFalse();
} catch (RaiseException re) {
return runtime.getFalse();
}
}
内容来源于网络,如有侵权,请联系作者删除!