You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: indices.rs
    path of file: ./repos/prisma-engines/schema-engine/connectors/mongodb-schema-connector/src/sampler/statistics
    
    the code of the file until where you have to start completion: use datamodel_renderer as renderer;
use mongodb_schema_describer::{IndexFieldProperty, IndexType, IndexWalker};
use psl::datamodel_connector::constraint_names::ConstraintNames;
use renderer::datamodel::{IndexDefinition, IndexFieldInput, Model};
use std::borrow::Cow;

pub(super) fn render<'a>(model: &mut Model<'a>, model_name: &str, indices: impl Iterator<Item = &'a IndexWalker<'a>>) {
    for index in indices {
        let fields = index.fields().map(|field| {
            let name = field
                .name()
                .split('.')
                .map(|part| {
                    super::sani
    
pub(super) fn render<'a>(model: &mut Model<'a>, model_name: &str, indices: impl Iterator<Item = &'a IndexWalker<'a>>) {
    for index in indices {
        let fields = index.fields().map(|field| {
            let name = field
                .name()
                .split('.')
                .map(|part| {
                    super::sanitize_string(part)
                        .map(Cow::Owned)
                        .unwrap_or_else(|| Cow::Borrowed(part))
                })
                .collect::<Vec<_>>()
                .join(".");

            let mut rendered = IndexFieldInput::new(name);

            match field.property {
                IndexFieldProperty::Text => (),
                IndexFieldProperty::Ascending if index.r#type().is_fulltext() => {
                    rendered.sort_order("Asc");
                }
                IndexFieldProperty::Descending => {
                    rendered.sort_order("Desc");
                }
                IndexFieldProperty::Ascending => (),
            }

            rendered
        });

        let mut rendered = match index.r#type() {
            IndexType::Normal => IndexDefinition::index(fields),
            IndexType::Unique => IndexDefinition::unique(fields),
            IndexType::Fulltext => IndexDefinition::fulltext(fields),
        };

        let column_names = index.fields().flat_map(|f| f.name().split('.')).collect::<Vec<_>>();

        let default_name = match index.r#type() {
            IndexType::Unique => {
                ConstraintNames::unique_index_name(model_name, &column_names, psl::builtin_connectors::MONGODB)
            }
            _ => ConstraintNames::non_unique_index_name(model_name, &column_names, psl::builtin_connectors::MONGODB),
        };

        if index.name() != default_name {
            rendered.map(index.name());
        };

        model.push_index(rendered);
    }
}