Remove direct membed access, use static member functions, remove a friend declaration.