$\pi$-$J/\psi$ Correlation and Elliptic Flow Parameter $v_2$ of Charmed Mesons at RHIC Energy