def METHOD_NAME():
    global schema, time, path, ogr, nat, layer, key, prefix, typ, firstrun, filetimewin
    schema = options["schema"]
    time = options["time"]
    path = os.path.join(os.path.dirname(os.path.realpath(__file__)), "tmp_%s" % schema)
    ##remove schema and tempfile
    if flags["r"]:
        try:
            os.remove(os.path.join(path, "firstrunlink"))
            os.remove(os.path.join(path, "firstrungauge"))
        except:
            print_message("Temp file not exists")
    # for links
    if options["type"].find("l") != -1:
        if options["vector"].find("l") != -1:
            # connect to line layer
            ogr = "link_ogr"
            nat = "link_nat"
            layer = "link"
            key = "linkid"
            prefix = "l"
            typ = "line"
            firstrun = "firstrunlink"
            filetimewin = "l_timewindow"
            run()
        else:
            # connect to points layer
            if not options["layername"]:
                grass.fatal("set up name of points layer")
            else:
                ogr = "point_ogr"
                nat = "points_nat"
                layer = "%s.%s" % (schema, options["layername"])
                key = "linkid"
                prefix = "l"
                typ = "point"
                firstrun = "firstrunlink"
                filetimewin = "l_timewindow"
                run()
    # for rain gaugues
    if options["type"].find("r") != -1:
        ogr = "gauge_ogr"
        nat = "gauge_nat"
        layer = "%s.rgauge" % schema
        key = "gaugeid"
        prefix = "g"
        typ = "point"
        firstrun = "firstrungauge"
        filetimewin = "g_timewindow"
        run()
    print_message("DONE")