Floodings of metric graphs