Application of nonlinear photonic crystal ring resonators in realizing all optical OR/NOT/AND gates