Pull knows how to pull data out of Xenia.
(d *Data)
| 39 | |
| 40 | // Pull knows how to pull data out of Xenia. |
| 41 | func (Xenia) Pull(d *Data) error { |
| 42 | switch rand.Intn(10) { |
| 43 | case 1, 9: |
| 44 | return io.EOF |
| 45 | |
| 46 | case 5: |
| 47 | return errors.New("Error reading data from Xenia") |
| 48 | |
| 49 | default: |
| 50 | d.Line = "Data" |
| 51 | fmt.Println("In:", d.Line) |
| 52 | return nil |
| 53 | } |
| 54 | } |
| 55 | |
| 56 | // Pillar is a system we need to store data into. |
| 57 | type Pillar struct{} |
nothing calls this directly
no outgoing calls
no test coverage detected