  With conformal-invariance methods, Burkhardt, Guim, and Xue studied the
critical Ising model, defined on the upper half plane $y>0$ with different
boundary conditions $a$ and $b$ on the negative and positive $x$ axes. For
$ab=-+$ and $f+$, they determined the one and two-point averages of the spin
$\sigma$ and energy $\epsilon$. Here $+$, $-$, and $f$ stand for spin-up,
spin-down, and free-spin boundaries, respectively. The case $+-+-+\dots$, where
the boundary conditions switch between $+$ and $-$ at arbitrary points,
$\zeta_1$, $\zeta_2$, $\dots$ on the $x$ axis was also analyzed.
  In this paper the alternating boundary conditions $+f+f+\dots$ and the case
$-f+$ of three different boundary conditions are considered. Exact results for
the one and two-point averages of $\sigma$, $\epsilon$, and the stress tensor
$T$ are derived. Using the results for $\langle T\rangle$, the critical Casimir
interaction with the boundary of a wedge-shaped inclusion is analyzed for mixed
boundary conditions.
  The paper also includes a comprehensive discussion of boundary-operator
expansions in two-dimensional critical systems with mixed boundary conditions.
Two types of expansions - away from switching points of the boundary condition
and at switching points - are considered. The asymptotic behavior of two-point
averages is expressed in terms of one-point averages with the help of the
expansions. We also consider the strip geometry with mixed boundary conditions
and derive the distant-wall corrections to one-point averages near one edge due
to the other edge using the boundary-operator expansions. The predictions of
the boundary-operator expansions are consistent with exact results for Ising
systems.
