LinkOption

  • LinkOption is an enum that defines how symbolic links are handled in Java NIO.2.

  • It implements OpenOption and CopyOption interfaces, allowing it to be used in file operations.

  • The primary enum value is NOFOLLOW_LINKS, which instructs operations to not follow symbolic links.

  • This enum is often used with methods like Files.getFileAttributeView, Files.copy, and SecureDirectoryStream.newByteChannel to control symbolic link behavior.

public final enum LinkOption extends Enum<LinkOption>
implements OpenOption CopyOption

Defines the options as to how symbolic links are handled.

Inherited Method Summary

Enum Values