Documentation ¶
Index ¶
- Constants
- func DataFilePrefix(dt DataType) string
- func WalkPrimaryPackages(r io.Reader, walkFn func(PrimaryPackage, int) error) error
- type DataType
- type FilelistsRoot
- type OtherRoot
- type PrimaryPackage
- type PrimaryRoot
- type RepoMdData
- type RepoMdDataChecksum
- type RepoMdDataLocation
- type RepoMdDistro
- type RepoMdDistroRoot
- type RepoMdRoot
- type XMLRoot
Constants ¶
View Source
const ( RepomdXMLFile = "repomd.xml" PrimaryXMLFile = "primary.xml" FilelistsXMLFile = "filelists.xml" OtherXMLFile = "other.xml" PrimaryHeaderFormat = "<metadata xmlns=\"http://linux.duke.edu/metadata/common\" rpm=\"http://linux.duke.edu/metadata/rpm\" packages=\"%d\">" FilelistsHeaderFormat = "<filelists xmlns=\"http://linux.duke.edu/metadata/filelists\" packages=\"%d\">" OtherHeaderFormat = "<otherdata xmlns=\"http://linux.duke.edu/metadata/other\" packages=\"%d\">" )
Variables ¶
This section is empty.
Functions ¶
func DataFilePrefix ¶
func WalkPrimaryPackages ¶
Types ¶
type FilelistsRoot ¶
type FilelistsRoot struct { XMLName xml.Name `xml:"filelists,omitempty"` Xmlns string `xml:"xmlns,attr,omitempty"` PackageCount int `xml:"packages,attr,omitempty"` Packages []byte `xml:",innerxml"` }
func (*FilelistsRoot) Data ¶
func (r *FilelistsRoot) Data() []byte
func (*FilelistsRoot) Href ¶
func (r *FilelistsRoot) Href(string)
type OtherRoot ¶
type PrimaryPackage ¶
type PrimaryRoot ¶
type PrimaryRoot struct { XMLName xml.Name `xml:"metadata,omitempty"` Xmlns string `xml:"xmlns,attr,omitempty"` XmlnsRpm string `xml:"xmlns:rpm,attr,omitempty"` Rpm string `xml:"rpm,attr,omitempty"` PackageCount int `xml:"packages,attr,omitempty"` Packages []byte `xml:",innerxml"` }
func (*PrimaryRoot) Data ¶
func (r *PrimaryRoot) Data() []byte
func (*PrimaryRoot) Href ¶
func (r *PrimaryRoot) Href(href string)
type RepoMdData ¶
type RepoMdData struct { Type string `xml:"type,attr,omitempty"` Checksum *RepoMdDataChecksum `xml:"checksum,omitempty"` OpenChecksum *RepoMdDataChecksum `xml:"open-checksum,omitempty"` Location *RepoMdDataLocation `xml:"location,omitempty"` Timestamp int64 `xml:"timestamp,omitempty"` Size int `xml:"size,omitempty"` OpenSize int `xml:"open-size,omitempty"` DatabaseVersion string `xml:"database_version,omitempty"` }
type RepoMdDataChecksum ¶
type RepoMdDataLocation ¶
type RepoMdDataLocation struct {
Href string `xml:"href,attr,omitempty"`
}
type RepoMdDistro ¶
type RepoMdDistroRoot ¶
type RepoMdDistroRoot struct {
Distro []*RepoMdDistro `xml:"distro,omitempty"`
}
type RepoMdRoot ¶
type RepoMdRoot struct { XMLName xml.Name `xml:"repomd,omitempty"` Xmlns string `xml:"xmlns,attr,omitempty"` XmlnsRpm string `xml:"xmlns:rpm,attr,omitempty"` Rpm string `xml:"rpm,attr,omitempty"` Revision string `xml:"revision,omitempty"` Tags *RepoMdDistroRoot `xml:"tags,omitempty"` Data []*RepoMdData `xml:"data,omitempty"` }
func ParseRepomd ¶
func ParseRepomd(r io.Reader) (*RepoMdRoot, error)
Click to show internal directories.
Click to hide internal directories.