Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Resource ¶
type Resource struct { LastRefresh time.Time // Last time the index was downloaded IndexURL url.URL // The URL used to host the index.json IndexFile paths.Path // The location of the index on the filesystem IndexSignature paths.Path // The location of the signature on the filesystem }
Resource represent the index of the system
func Init ¶
Init will initialize the IndexResource structure and will return it. It will take indexString as a paramenter.
func (*Resource) DownloadAndVerify ¶
DownloadAndVerify will download an index file located at IndexURL and verify the signature if everything matches the files are overwritten
Click to show internal directories.
Click to hide internal directories.