def METHOD_NAME(fp_xml):
    fp = FlightPlan()
    fp_tree = etree.METHOD_NAME(fp_xml)
    fp_element = fp_tree.find("flight_plan")
    fp.name = get_attrib(fp_element, "name")
    fp.lat0 = get_attrib(fp_element, "lat0")
    fp.lon0 = get_attrib(fp_element, "lon0")
    fp.max_dist_from_home = get_attrib(fp_element, "max_dist_from_home")
    fp.ground_alt = get_attrib(fp_element, "ground_alt")
    fp.security_height = get_attrib(fp_element, "security_height")
    fp.alt = get_attrib(fp_element, "alt")
    if fp_element.find("header") is not None:
        fp.header = fp_element.find("header").text
    ways_elt = fp_element.find("waypoints")
    fp.waypoints = FlightPlan.parse_waypoints(ways_elt)
    blocks_elt = fp_element.find("blocks")
    fp.blocks = FlightPlan.parse_blocks(blocks_elt)
    excs_elt = fp_element.find("exceptions")
    fp.exceptions = FlightPlan.parse_exceptions(excs_elt)
    return fp