Java Code Examples for java.nio.file.FileStore#toString()

The following examples show how to use java.nio.file.FileStore#toString() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ESFileStore.java    From Elasticsearch with Apache License 2.0 5 votes vote down vote up
private static String getMountPointLinux(FileStore store) {
    String desc = store.toString();
    int index = desc.lastIndexOf(" (");
    if (index != -1) {
        return desc.substring(0, index);
    } else {
        return desc;
    }
}
 
Example 2
Source File: IOUtils.java    From lucene-solr with Apache License 2.0 5 votes vote down vote up
static String getMountPoint(FileStore store) {
  String desc = store.toString();
  int index = desc.lastIndexOf(" (");
  if (index != -1) {
    return desc.substring(0, index);
  } else {
    return desc;
  }
}
 
Example 3
Source File: ESFileStore.java    From crate with Apache License 2.0 5 votes vote down vote up
private static String getMountPointLinux(final FileStore store) {
    String desc = store.toString();
    int index = desc.lastIndexOf(" (");
    if (index != -1) {
        return desc.substring(0, index);
    } else {
        return desc;
    }
}