2
我的FTPClient
API在仔細閱讀以下聲明:Apache的公網FTPClient storeUniqueFile使用
boolean storeUniqueFile(InputStream local)
Stores a file on the server using a unique name assigned by the server and taking input from the given InputStream.
我怎麼知道的唯一名稱或路徑分配給服務器文件?有沒有人使用過此API?
我不認爲你應該作爲客戶端,你只是發送文件到服務器,它會處理命名,你可能有功能cd到一個特定的文件夾,但是當你去保存文件時,服務器端可能只是接管並處理重複名稱。 – mikemil