It's not a secret anymore!
The moose likes Java in General and the fly likes Question about Files.WalkFileTree method Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Question about Files.WalkFileTree method" Watch "Question about Files.WalkFileTree method" New topic
Author

Question about Files.WalkFileTree method

Nick Widelec
Ranch Hand

Joined: Feb 28, 2013
Posts: 226

The first just requires the starting directory and a FileVisitor object i.e.:


the second:


In a real application I would like to use the following
This works. However it appears to be only FOLLOW_LINKS as a possible choice of a FileVisitOption.
Therefore I wonder why in the second walkFileTree method, the second parameter is a set of FileVisitOption... I mean there is only one possible choice which is FOLLOW_LINKS. Am I missing something?
Thanks in advance.

OCAJP 7, OCPJP 7
Stephan van Hulst
Bartender

Joined: Sep 20, 2010
Posts: 4003
    
  18

In the future, more values may be added.


The mind is a strange and wonderful thing. I'm not sure that it will ever be able to figure itself out, everything else, maybe. From the atom to the universe, everything, except itself.
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: Question about Files.WalkFileTree method
 
It's not a secret anymore!