The Swedish subsidiary of the Danish brewer Carlsberg is to end production at its Stockholm brewery, resulting in 300 job losses.