An apparatus for controlling a flow of fluid in a lumen formed by a tissue wall ofa patient's vas deference comprises an implantable constriction devicefor gently constricting (i.e. without substantially hampering the blood circulationin the tissue wall) at least one portion of the tissue wall to influence the flowin the lumen, and a stimulation device for stimulating the wall portion of thetissue wall. A control device controls the stimulation device to stimulate thewall portion, as the constriction device constricts the wall portion, to causecontraction of the wall portion constricted by the constriction device to furtherinfluence the flow in the lumen. The apparatus can be used for restricting or stoppingthe flow in the lumen, or for actively moving the fluid in the lumen, with a low riskof injuring the vas deference.