I am studying Ornstein-Uhlenbeck model: $$ dX_t = -A_0 X_t dt + dW_t,$$ where the initial value $X_0$ is given, and $W_t$ is standard Brownian motion. G.Matulewicz in his doctoral thesis writes that the negative log-likelihood is given by $$ L(A) = \frac{1}{T}\int_{0}^{T} (A X_t)^T dX_t + \frac{1}{2T}\int_{0}^{T} (A X_t)^T A X_t dt $$
Then, the MLE estimator is given by $$ \hat{A} = - \left(\int_{0}^T dX_t X_t^T\right) \left(\int_{0}^T X_t X_t^T dt\right)^{-1}$$ However, I have no idea how the calculus between those lines follow and I would like to understand the technical part (to be able to use those techniques for other more general processes). Can anyone explain?