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: rainfall.rs
    path of file: ./repos/charming/gallery/src/line
    
    the code of the file until where you have to start completion: use charming::{
    component::{
        Axis, DataZoom, DataZoomType, Feature, Grid, Legend, Restore, SaveAsImage, Title, Toolbox,
        ToolboxDataZoom,
    },
    element::{
        AreaStyle, AxisLine, AxisPointer, AxisPointerType, AxisType, Emphasis, EmphasisFocus,
        ItemStyle, Label, LineStyle, MarkArea, MarkAreaData, NameLocation, Tooltip, Trigger,
    },
    series::Line,
    Chart,
};

pub fn chart() -> Chart {
    let time_data = TIME.iter().map(|&x| x.to_string()).collect::<Vec<_>>();
    let flow_data = FLOW_DATA.to_vec();
    let rainfall_data = RAINFALL_DATA.to_vec();

    Chart::new()
        .title(
            Title::new()
                .text("Rainfall and Flow Relationship")
                .left("center"),
        )
        .grid(Grid::new().bottom(80))
        .toolbox(
            Toolbox::new().feature(
                Feature::new()
                    .data_zoom(ToolboxDataZoom::new().y_axis_index("none"))
                    .restore(Restore::new())
                    .save_as_image(SaveAsImage::new()),
            ),
        )
        .tooltip(
            Tooltip::new().trigger(Trigger::Axis).axis_pointer(
                AxisPointer::new()
                    .type_(AxisPointerType::Cross)
                    .animation(false)
                  
    
pub fn chart() -> Chart {
    let time_data = TIME.iter().map(|&x| x.to_string()).collect::<Vec<_>>();
    let flow_data = FLOW_DATA.to_vec();
    let rainfall_data = RAINFALL_DATA.to_vec();

    Chart::new()
        .title(
            Title::new()
                .text("Rainfall and Flow Relationship")
                .left("center"),
        )
        .grid(Grid::new().bottom(80))
        .toolbox(
            Toolbox::new().feature(
                Feature::new()
                    .data_zoom(ToolboxDataZoom::new().y_axis_index("none"))
                    .restore(Restore::new())
                    .save_as_image(SaveAsImage::new()),
            ),
        )
        .tooltip(
            Tooltip::new().trigger(Trigger::Axis).axis_pointer(
                AxisPointer::new()
                    .type_(AxisPointerType::Cross)
                    .animation(false)
                    .label(Label::new().background_color("#505765")),
            ),
        )
        .legend(Legend::new().data(vec!["Flow", "Rainfall"]).left(10))
        .data_zoom(DataZoom::new().show(true).realtime(true).start(65).end(85))
        .data_zoom(
            DataZoom::new()
                .type_(DataZoomType::Inside)
                .realtime(true)
                .start(65)
                .end(85),
        )
        .x_axis(
            Axis::new()
                .type_(AxisType::Category)
                .boundary_gap(false)
                .axis_line(AxisLine::new().on_zero(false))
                .data(time_data),
        )
        .y_axis(Axis::new().name("Flow(mÂ³/s)").type_(AxisType::Value))
        .y_axis(
            Axis::new()
                .name("Rainfall(mm)")
                .name_location(NameLocation::Start)
                .type_(AxisType::Value)
                .inverse(true)
                .align_ticks(true),
        )
        .series(
            Line::new()
                .name("Flow")
                .area_style(AreaStyle::new())
                .line_style(LineStyle::new().width(1))
                .emphasis(Emphasis::new().focus(EmphasisFocus::Series))
                .mark_area(
                    MarkArea::new()
                        .silent(true)
                        .item_style(ItemStyle::new().opacity(0.3))
                        .data(vec![(
                            MarkAreaData::new().x_axis("2009/9/12\n7:00"),
                            MarkAreaData::new().x_axis("2009/9/22\n7:00"),
                        )]),
                )
                .data(flow_data),
        )
        .series(
            Line::new()
                .name("Rainfall")
                .y_axis_index(1)
                .area_style(AreaStyle::new())
                .line_style(LineStyle::new().width(1))
                .emphasis(Emphasis::new().focus(EmphasisFocus::Series))
                .mark_area(
                    MarkArea::new()
                        .silent(true)
                        .item_style(ItemStyle::new().opacity(0.3))
                        .data(vec![(
                            MarkAreaData::new().x_axis("2009/9/12\n7:00"),
                            MarkAreaData::new().x_axis("2009/9/22\n7:00"),
                        )]),
                )
                .data(rainfall_data),
        )
}