  We study the interactions of a Bragg-grating soliton with a localized
attractive defect which is a combined perturbation of the grating and
refractive index. A family of exact analytical solutions for solitons trapped
by the delta-like defect is found. Direct simulations demonstrate that, up to
the numerical accuracy available, the trapped soliton is stable at a single
value of its intrinsic parameter ("mass"). Trapped solitons with larger mass
relax to the stable one through the emission of radiation, while the solitons
with smaller mass decay. Depending on values of parameters, simulations of
collisions between moving solitons and the defect show that the soliton can get
captured, pass through, or even bounce from the defect. If the defect is strong
and the soliton is heavy enough, it may split, as a result of the collision,
into three fragments: trapped, transmitted, and reflected ones.
