Recently, manipulation and measurement of quantum states, especially in quantum cavities, have attracted the attention of many researchers in different fields, such as quantum optics, quantum information, and quantum computation. In this paper, a non-demolition method for the measurement of squeezing parameter via atomic Mach-Zehnder interferometer is presented. An experimental setup was also proposed which included two quantum cavities, in different arms of an atomic Mach-Zehnder interferometer. Each quantum cavity was settled between two classical cavities. Quantum cavities contained entangled states with arbitrary squeezed photons. It is shown that the outgoing atomic states of Mach-Zehnder interferometer carry on the properties and situation of quantum states of the cavities. The squeezing parameter of photonic state for one of the cavities is obtained by the detection of excited and non-excited probabilities of Mach-Zehnder interferometer's outgoing ports, for a train of incoming two-level Rydberg atoms.