Large Deviations For Markov Jump Processes And Hamiltonian Trajectories