3

以下を使用するときに参照される属性名のリストがあるかどうか疑問に思っています:

ただし、次のように setAttribute(Path, String, Object, LinkOption...) メソッドを使用して DOS 属性を設定できます。

パス ファイル = ...; Files.setAttribute(file, "dos:hidden", true);

この場合、.isHidden()メソッドは と呼ばれhiddenますisReadOnly()。他の組み合わせも試してみdos:readOnlyましたが、望んだ結果が得られませんでした。これらの属性「参照」のリストがあるリンクを知っていますか? 前もって感謝します。

4

1 に答える 1

3

http://www.kodejava.org/how-do-i-set-the-value-of-file-attributes/

//
// Set a new file attributes.
//
Files.setAttribute(file, "dos:archive", false);
Files.setAttribute(file, "dos:hidden", false);
Files.setAttribute(file, "dos:readonly", false);
Files.setAttribute(file, "dos:system", false);
于 2013-08-07T17:12:35.503 に答える