When is a real-valued continuous function on the unit circle the real part of a holomorphic function on the unit disk? This is known, but it is taking me some time to find the relevant result. Let $u: \partial D \to \mathbb{R}$ be a continuous function, where $D$ is the open unit disk in the complex plane. What are necessary and sufficient conditions on $u$, so that there exists a holomorphic function $f: D \to \mathbb{C}$ which extends continuously to a function from $\bar{D}$ to $\mathbb{C}$, and such that
$Re(f|_{\partial D}) = u$ on $\partial D$.
A related question is this. Suppose I apply the Schwarz integral formula to $u$. Under what conditions will this give me a function $f$ satisfying the properties above?
Edit: Thanks to Kavi Rama Murthy, who referred me to a theorem in Rudin's Real and Complex Analysis, I know that there is a holomorphic function $f: D \to \mathbb{C}$ such that $Re(f)$ extends continuously to a continuous function from $\bar{D} \to \mathbb{R}$ and agrees with $u$ on $\partial D$. My concern is this. Are we guaranteed that $Im(f)$ also extends continuously to a continuous function $\bar{D} \to \mathbb{R}$?
The issue I am worrying about is the following. Let $f: D \to \mathbb{C}$ be holomorphic, such that $Re(f)$ extends to a continuous function $\bar{D} \to \mathbb{R}$. Are we guaranteed that $Im(f)$ also extends to a continuous function $\bar{D} \to \mathbb{R}$? Maybe the question is trivial, but I don't see the answer immediately.
Edit 2: Using Rudin's Real and Complex Analysis book, more specifically the chapter on $H^p$ spaces, that Kavi Rama Murthy referred me to in his (edited) answer (thank you once more!), one can say that necessary and sufficient conditions for a continuous complex-valued function on $\partial D$ to be the radial limit of a holomorphic function defined in $D$, is for it to have vanishing Fourier coefficients for all negative frequencies (this follows from a theorem by Titchmarsh). But this does not exactly answer my original question yet.
When is a continuous real function on $\partial D$ the real part of a complex-valued continuous function on $\partial D$ with vanishing Fourier coefficients for all negative frequencies? I feel that this is much easier to answer though than my original question.
Edit 3: Towards answering my question in edit 2, can't one do a folding of the Fourier coefficients? What I mean is the following. Let $u$ be a real continuous function on $\partial D$. Write
$u = u_- + u_0 + u_+$
where $u_-$ is the negative frequency part of $u$, $u_+$ is its positive frequency part, and $u_0$ is its constant part. Note that $u_-$ is the complex conjugate of $u_+$.
Then define the function $u_0 + 2 u_+$ on $\partial D$. Its real part is $u$ and, moreover, all its negative frequency terms vanish. This shows that given a continuous function $u: \partial D \to \mathbb{R}$, there always exists a holomorphic function $f: D \to \mathbb{C}$, whose radial limits $f^*(\theta)$ exist almost everywhere on $\partial D$ and such that $Re(f) = u$ on the boundary $\partial D$. Can someone please confirm if the argument outlined here makes sense? Many thanks to Kavi Rama Murthy! The only subtlety remaining here is that $f^*$ is obtained from $f$ by radial limits. If one defines a new function $F$ by $f$ on $D$ and by $f^*$ on $\partial D$, is $F$ necessarily continuous? Or, what extra conditions can we impose on $u$ to guarantee continuity of $F$?
Edit 4: it turns out, after a private communication with a complex analysis expert, that the answer to my original question is in general "no". Indeed, one can construct a Riemann map from the open unit disk onto a kind of vertical strip, which gets narrower and narrower as you approach infinity. Its real part extends continuously to the boundary, yet its imaginary part is discontinuous at two points (which get mapped to infinity). 
 A: The question in the title is a standard result in Complex Analysis and the holomorphic function can be constructed using Poisson integrals. Rudin's RCA has  a theorem which proves this. See the section on Poisson integral (second theorem in that section).  However not every continuous function on the boundary is the boundary function of a holomorphic function that extends continuously to the boundary. In particular if the function is zero on a set of positive measure it must be identically zero. See the chapter on $H_p$ spaces in Rudin for conditions on $f$.
A: After exchanging some emails with an expert in complex analysis (Chris Bishop), he informed me of the following. 
C. Bishop wrote "Consider the Riemann map  $f$ from the unit disk  to the unbounded simply connected region $W = \{ x+iy: 0 < x< 1/(1+y^2)\}$; this is like an infinite vertical strip, except that the ends get thinner as we move up or down to infinity. The real part u of f is bounded and continuous, but the imaginary part v is unbounded at two points, hence discontinuous.
In general, the boundary values of u and v are related by the Hilbert transform (this is given by a certain singular integral formal, or has a simple expression in terms of the Fourier transform and is one of the most well studied operators in analysis) and it turns out that (as in the example above), the Hilbert transform of a continuous function need not be continuous.  If one strengthens the continuity assumption to something like Holder continuous, then there is a positive result: the Hilbert transform of a Holder continuous function is also Holder continuous. The sharpest condition of this type is given by what is called a 'Dini condition' (e.g., see Theorem II.1.3 of John Garnett's book 'Bounded Analytic Functions');  most continuous functions  arising in practice will satisfy this, so the answer to your originally question is that  very often f will extend continuously to the circle, but there are a few, slightly exotic, examples where it does not.
For the definitions of Hilbert transform and Dini continuous  see (or many books on Harmonic or Euclidean analysis)
https://en.wikipedia.org/wiki/Hilbert_transform
https://en.wikipedia.org/wiki/H%C3%B6lder_condition
https://en.wikipedia.org/wiki/Dini_continuity"
I am uneasy with getting points for information someone else gave, so please do not upvote this answer. I did get C. Bishop's consent though, and I am only posting it because it could be useful to others. 
A: If you are lucky enough to have
$$\sum_{n=-\infty}^{\infty}|\hat u (n)|<\infty,$$
where $\hat u (n)$ is the $n$th Fourier coefficient of $u,$ then the unique harmonic conjugate $v$ of $u$ with $v(0)=0$ has the same property. This is simple: $\hat v (n) = -i(\text {sgn }n)\hat u (n)$ for each $n.$ It follows that $u+iv$ is continuous on the closed disc. 
