Shares Under IP

前端 未结 3 677
故里飘歌
故里飘歌 2020-12-10 17:48

How to list all the available shared folders under a specific IP Address?

Mock code:

IP ip = new IP(\"10.0.0.9\");

for(File share : ip.getSharedFold         


        
3条回答
  •  -上瘾入骨i
    2020-12-10 18:28

    If the files are accessible through the server IP address (network wise and permission wise) then sure you can list them all recursively by doing the following:

    1. Get the remote folder name. Example "//10.0.0.9/folder"
    2. Iterate through that folder just as you would do to list files in a local directory (see this link to know more about listing local files in a local directory

提交回复
热议问题