parsePoint returns a Point from the given string, or the origin if the string was invalid. If more than one value is given, only the first is used.
(s string)
| 64 | // parsePoint returns a Point from the given string, or the origin if the |
| 65 | // string was invalid. If more than one value is given, only the first is used. |
| 66 | func parsePoint(s string) Point { |
| 67 | p := parsePoints(s) |
| 68 | if len(p) > 0 { |
| 69 | return p[0] |
| 70 | } |
| 71 | |
| 72 | return Point{r3.Vector{X: 0, Y: 0, Z: 0}} |
| 73 | } |
| 74 | |
| 75 | // pointToString returns a string representation suitable for reconstruction |
| 76 | // by the parsePoint method. |
no test coverage detected
searching dependent graphs…