{ fn:exists(Segment[1]/SOI) } { fn:exists(Segment[fn:count(Segment)]/EOI) }