当前位置: 首页>>代码示例>>Java>>正文


Java FileSystem类代码示例

本文整理汇总了Java中org.gradle.internal.nativeintegration.filesystem.FileSystem的典型用法代码示例。如果您正苦于以下问题:Java FileSystem类的具体用法?Java FileSystem怎么用?Java FileSystem使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


FileSystem类属于org.gradle.internal.nativeintegration.filesystem包,在下文中一共展示了FileSystem类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getUnixMode

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
@Override
public int getUnixMode(File f) throws IOException {
    if (f.isDirectory()) {
        return FileSystem.DEFAULT_DIR_MODE;
    } else if (f.exists()) {
        return FileSystem.DEFAULT_FILE_MODE;
    } else {
        throw new FileNotFoundException(String.format("File '%s' not found.", f));
    }
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:11,代码来源:FallbackStat.java

示例2: getMode

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public int getMode() {
    int unixMode = entry.getUnixMode() & 0777;
    if (unixMode == 0) {
        //no mode infos available - fall back to defaults
        if (isDirectory()) {
            unixMode = FileSystem.DEFAULT_DIR_MODE;
        } else {
            unixMode = FileSystem.DEFAULT_FILE_MODE;
        }
    }
    return unixMode;
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:13,代码来源:ZipFileTree.java

示例3: parser

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public static NotationParser<Object, Object> parser(FileSystem fileSystem) {
    return NotationParserBuilder
            .toType(Object.class)
            .typeDisplayName("a File or URI")
            .converter(new FileOrUriNotationConverter(fileSystem))
            .toComposite();
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:8,代码来源:FileOrUriNotationConverter.java

示例4: contains

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public static boolean contains(FileSystem fileSystem, DirectoryTree tree, File file) {
    String prefix = tree.getDir().getAbsolutePath() + File.separator;
    if (!file.getAbsolutePath().startsWith(prefix)) {
        return false;
    }

    RelativePath path = RelativePath.parse(true, file.getAbsolutePath().substring(prefix.length()));
    return tree.getPatterns().getAsSpec().isSatisfiedBy(new DefaultFileTreeElement(file, path, fileSystem, fileSystem));
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:10,代码来源:DirectoryTrees.java

示例5: DirectoryFileTree

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
DirectoryFileTree(File dir, PatternSet patternSet, Factory<DirectoryWalker> directoryWalkerFactory, FileSystem fileSystem, boolean postfix) {
    this.patternSet = patternSet;
    this.dir = dir;
    this.directoryWalkerFactory = directoryWalkerFactory;
    this.fileSystem = fileSystem;
    this.postfix = postfix;
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:8,代码来源:DirectoryFileTree.java

示例6: CopyFileVisitorImpl

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public CopyFileVisitorImpl(CopySpecResolver spec, CopyActionProcessingStreamAction action, Instantiator instantiator, FileSystem fileSystem) {
    this.copySpecResolver = spec;
    this.action = action;
    this.instantiator = instantiator;
    this.fileSystem = fileSystem;
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:7,代码来源:CopyFileVisitorImpl.java

示例7: getUnixMode

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public int getUnixMode(File f) throws IOException {
    if (f.isDirectory()) {
        return FileSystem.DEFAULT_DIR_MODE;
    } else if (f.exists()) {
        return FileSystem.DEFAULT_FILE_MODE;
    } else {
        throw new FileNotFoundException(String.format("File '%s' not found.", f));
    }
}
 
开发者ID:Pushjet,项目名称:Pushjet-Android,代码行数:10,代码来源:FallbackStat.java

示例8: getMode

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public int getMode() {
    int unixMode = entry.getUnixMode() & 0777;
    if(unixMode == 0){
        //no mode infos available - fall back to defaults
        if(isDirectory()){
            unixMode = FileSystem.DEFAULT_DIR_MODE;
        }else{
            unixMode = FileSystem.DEFAULT_FILE_MODE;
        }
    }
    return unixMode;
}
 
开发者ID:Pushjet,项目名称:Pushjet-Android,代码行数:13,代码来源:ZipFileTree.java

示例9: create

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public static NotationParser<Object, Object> create(FileSystem fileSystem) {
    return NotationParserBuilder
            .toType(Object.class)
            .typeDisplayName("a File or URI")
            .converter(new FileOrUriNotationParser(fileSystem))
            .toComposite();
}
 
开发者ID:Pushjet,项目名称:Pushjet-Android,代码行数:8,代码来源:FileOrUriNotationParser.java

示例10: createLink

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public void createLink(String target) {
    NativeServices.getInstance().get(FileSystem.class).createSymbolicLink(this, new File(target));
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:4,代码来源:TestFile.java

示例11: getFileSystem

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
@Inject
protected FileSystem getFileSystem() {
    throw new UnsupportedOperationException();
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:5,代码来源:InstallExecutable.java

示例12: getFileSystem

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
@Inject
protected FileSystem getFileSystem() {
    // Decoration takes care of the implementation
    throw new UnsupportedOperationException();
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:6,代码来源:Delete.java

示例13: DefaultClasspathSnapshotter

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public DefaultClasspathSnapshotter(FileHasher hasher, StringInterner stringInterner, FileSystem fileSystem, DirectoryFileTreeFactory directoryFileTreeFactory) {
    super(hasher, stringInterner, fileSystem, directoryFileTreeFactory);
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:4,代码来源:DefaultClasspathSnapshotter.java

示例14: AbstractFileCollectionSnapshotter

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public AbstractFileCollectionSnapshotter(FileHasher hasher, StringInterner stringInterner, FileSystem fileSystem, DirectoryFileTreeFactory directoryFileTreeFactory) {
    this.hasher = hasher;
    this.stringInterner = stringInterner;
    this.fileSystem = fileSystem;
    this.directoryFileTreeFactory = directoryFileTreeFactory;
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:7,代码来源:AbstractFileCollectionSnapshotter.java

示例15: DefaultGenericFileCollectionSnapshotter

import org.gradle.internal.nativeintegration.filesystem.FileSystem; //导入依赖的package包/类
public DefaultGenericFileCollectionSnapshotter(FileHasher hasher, StringInterner stringInterner, FileSystem fileSystem, DirectoryFileTreeFactory directoryFileTreeFactory) {
    super(hasher, stringInterner, fileSystem, directoryFileTreeFactory);
}
 
开发者ID:lxxlxx888,项目名称:Reer,代码行数:4,代码来源:DefaultGenericFileCollectionSnapshotter.java


注:本文中的org.gradle.internal.nativeintegration.filesystem.FileSystem类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。