Abstract data type semantics for many-sorted query algebras