public Model mapTraits(Model model, BiFunction<Shape, Trait, Trait> mapper) {
        return new MapTraits(mapper).transform(this, model);
    }
Maps over all traits in the model using a mapping function that accepts
the shape the trait is applied to, a trait, and returns a trait,
possibly even a different kind of trait.

<p>An exception is thrown if a trait is returned that targets a
different shape than the {@link Shape} passed into the mapper function.

@param model Model to transform.
@param mapper Mapping function that accepts a (Shape, Trait) and returns
 the mapped Trait.
@return Returns the transformed model.base.
smithy-model/src/main/java/software/amazon/smithy/model/transform/ModelTransformer.java