If $X:\Omega\times\mathbb{R}\rightarrow\mathbb{R}$ is a stochastic process which is a semimartingale (that is one can write X as the sum of a local martingale starting at zero and a process of finite variation; so every martingale starting at zero is a semimartingale), the stochastic integral $$\int_0^Tf(t)dX(t)$$ (sometimes also written as $(f\dot\ X)_T$) is first defined for simple predictable processes $f$ of the form $f=1_{\{(\omega,t)|r
If $X$ is a process of finite variation (hence it is a semimartingale), then the stochastic integral $(f\dot\ X)_T$ is just the Lebesgue–Stieltjes-integral.
Under certain conditions, if $(X_t)_{t\geq 0}$ is a martingale, then also $((f\dot\ X)_T)_{T\geq 0}=(\int_0^Tf(t)X_t)_{T\geq 0}$ is a martingale.
To understand the process of defining the stochastic integral, i suggest to look it up in any stochastic calculus text book.