4. The number of all different integer solutions to the equation $2 x^{2}+5 x y+2 y^{2}=2007$ is $\qquad$ groups.

将上面的文本翻译成英文，请保留源文本的换行和格式，直接输出翻译结果。 

Note: The note above is not part of the translation but is provided to clarify the instruction. The actual translation is above this note.
4.4 .

Let's first assume $x \geqslant y$, the original equation can be transformed into $(2 x+y)(x+2 y)=2007$.
Since $2007=2007 \times 1=669 \times 3=223 \times 9$
$$
\begin{array}{l}
=(-1) \times 2007=(-3) \times(-669) \\
=(-9) \times(-223),
\end{array}
$$

Therefore, $\left\{\begin{array}{l}2 x+y=2007, \\ x+2 y=1 .\end{array}\right.$,
Solving gives $3(x+y)=2008$, which has no integer solutions.
Similarly, $\left\{\begin{array}{l}2 x+y=223, \quad-1,-9 \\ x+2 y=9,-2007,-223,\end{array}\right.$ all have no integer solutions;
$\left\{\begin{array}{l}2 x+y=-3, \\ x+2 y=-669\end{array}\right.$ has integer solutions $\left\{\begin{array}{l}x=221, \\ y=-445 .\end{array}\right.$
If $y \geqslant x$, there are two more sets of integer solutions
$$
\left\{\begin{array} { l } 
{ x = - 2 2 1 , } \\
{ y = 4 4 5 , }
\end{array} \left\{\begin{array}{l}
x=-445, \\
y=221 .
\end{array}\right.\right.
$$

Therefore, there are a total of 4 sets of integer solutions.