A sluice is a water channel that is controlled at its head by a gate. A sluice gate is traditionally a wooden or metal plate which slides in grooves in the sides of the channel.
Raising a sluice gate allows water to flow under it. (The term sluice gate refers to any gate that operates by allowing water to flow under it.) When a sluice gate is fully lowered, water sometimes spills over the top, in which case the gate operates as a weir.
Usually a mechanism drives the sluice gate up or down. This may be a simple, hand-operated, worm drive or rack and pinion drive, or it may be electrically or hydraulically powered.
The gates of a lock may work in a way similar to the way a sluice gate works, but traditional canal lock gates are hinged to swing like double doors.