(b) Whoever, except as provided by law, carries on his person, or carries on his person or under his control in a vehicle, any stiletto, dagger or a device or case which enables a knife with a locking blade to be drawn at a locked position, any ballistic knife, or any knife with a detachable blade capable of being propelled by any mechanism, dirk knife, any knife having a double-edged blade, or a switch knife, or any knife having an automatic spring release device by which the blade is released from the handle,
..., shall be punished by imprisonment for not less than two and one-half years nor more than five years in the state prison, or for not less than six months nor more than two and one-half years in a jail or house of correction.