github.com/cloud-foundations/dominator@v0.0.0-20221004181915-6e4fee580046/lib/images/virtualbox/api.go (about) 1 package virtualbox 2 3 import ( 4 "io" 5 ) 6 7 type Reader struct { 8 Description string 9 Header string 10 MajorVersion uint16 11 MinorVersion uint16 12 Size uint64 13 blockIndex uint32 14 blockMap map[uint32]struct{} 15 blockOffset uint32 16 blockSize uint32 17 blocksInHDD uint32 18 reader io.Reader 19 } 20 21 func NewReader(r io.Reader) (*Reader, error) { 22 return newReader(r) 23 } 24 25 func (r *Reader) Read(p []byte) (int, error) { 26 return r.read(p) 27 }