All-Optical Integrated Logic Operations Based on Chemical Communication Between Molecular Switches