I used FilesystemContainer in a Vaadin 7 application to populate the contents of a com.vaadin.ui.Tree for viewing and selecting files on the server.
tree.setContainerDataSource (new FilesystemContainer (new File ("o: \\")));
However, when migrating this application to Vaadin 8 I did not find an alternative to the FilesystemContainer. Could anyone tell me which way would be the best?
This is missing feature in Vaadin 8 and subsequent versions, but thanks for the idea. It is not very complex task to implement FilesystemDataProvider
in Vaadin 8, thus I made one:
https://vaadin.com/directory/component/filesystem-dataprovider-add-on
The source code and demo application are in GitHub, see demo application how to use:
https://github.com/TatuLund/FilesystemDataProvider/blob/master/filesystemdataprovider-demo/src/main/java/org/vaadin/filesystemdataprovider/demo/DemoUI.java
There is version also for the new Vaadin versions like Vaadin 14 as well. In Vaadin 14 version there is FTP variant too.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With