Investigation on photonic crystal based all-optical clocked D-flip flop