You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to get the upload/download summary and I see an example in the readme. Which utils module is it coming from? There's a number in this project and I can't seem to find FileInfo in any of them.
Hey Andy, it looks like they changed the function names and combined the return values into a new struct in #299. I think the README example should reference the following util pkgs:
import (
sutils "github.com/jfrog/jfrog-client-go/artifactory/services/utils""github.com/jfrog/jfrog-client-go/utils"
)
...// Download files with summary exampleparams:=services.NewDownloadParams()
params.Pattern="repo/*/*.zip"params.Target="repo/path/"summary, err:=rtManager.DownloadFilesWithSummary(params)
defersummary.Close()
// Iterate over each file's ArtifactDetails// ArtifactDetails comes from: github.com/jfrog/jfrog-client-go/artifactory/services/utilsadNext:=summary.ArtifactsDetailsReader.NextRecordforad:=new(sutils.ArtifactDetails); adNext(ad) ==nil; ad=new(sutils.ArtifactDetails) {
fmt.Printf("ArtifactDetails: %+v\n", ad)
}
iferr:=summary.ArtifactsDetailsReader.GetError(); err!=nil {
returnerr
}
// Iterate over each file's TransferDetails// FileTransferDetails comes from: github.com/jfrog/jfrog-client-go/utilstdNext:=summary.TransferDetailsReader.NextRecordfortd:=new(utils.FileTransferDetails); tdNext(td) ==nil; td=new(utils.FileTransferDetails) {
fmt.Printf("FileTransferDetails: %+v\n", td)
}
iferr:=summary.TransferDetailsReader.GetError(); err!=nil {
returnerr
}
I think it works the same way for summaries returned from rtManager.UploadFilesWithSummary(params)
I'm trying to get the upload/download summary and I see an example in the readme. Which utils module is it coming from? There's a number in this project and I can't seem to find FileInfo in any of them.
The text was updated successfully, but these errors were encountered: