forked from jfrog/jfrog-client-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.go
48 lines (39 loc) · 1.05 KB
/
config.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
package artifactory
import (
"github.com/jfrog/jfrog-client-go/artifactory/auth"
"github.com/jfrog/jfrog-client-go/utils/log"
)
type Config interface {
GetCertificatesPath() string
GetThreads() int
IsDryRun() bool
GetArtDetails() auth.ArtifactoryDetails
GetLogger() log.Log
IsInsecureTls() bool
}
type artifactoryServicesConfig struct {
auth.ArtifactoryDetails
certificatesPath string
dryRun bool
threads int
logger log.Log
insecureTls bool
}
func (config *artifactoryServicesConfig) IsDryRun() bool {
return config.dryRun
}
func (config *artifactoryServicesConfig) GetCertificatesPath() string {
return config.certificatesPath
}
func (config *artifactoryServicesConfig) GetThreads() int {
return config.threads
}
func (config *artifactoryServicesConfig) GetArtDetails() auth.ArtifactoryDetails {
return config.ArtifactoryDetails
}
func (config *artifactoryServicesConfig) GetLogger() log.Log {
return config.logger
}
func (config *artifactoryServicesConfig) IsInsecureTls() bool {
return config.insecureTls
}