Polyline Gaps

For #2136.

CC @shunter @mramato 
`equalsEpsilonRelative` doesn't exist anymore.