Classification problems for Hamiltonian evolutionary equations and their discretizations