I'm developing in Windows and somewhere in the flow I have to access sftp (Linux) server. I do some logic to prepare filenames I have to copy from the sftp server and I need to generate the full path, therefore I write this line in my code:
Paths.get(configuration.getSftpServerConfiguration().getRemotePath(), filename).toString();
Because I’m running on Windows the paths generated with Windows slash, for example \public\directory\filename.csv
Can I define Paths to work with Linux separator? (I know I can concatenate ‘/’ by myself but looks for me like a bad practice..)