#!/usr/bin/env python3 import bpaTools import groundEstimatedHeight from groundEstimatedHeight import GroundEstimatedHeight if __name__ == '__main__': ### Context applicatif callingContext = "Paragliding-OpenAir-FrenchFiles" #Your app calling context linkContext = "http://pascal.bazile.free.fr/paraglidingFolder/divers/GPS/OpenAir-Format/" appName = "groundEstimatedHeight" #or your app name appPath = bpaTools.getFilePath(__file__) #or your app path appVersion = groundEstimatedHeight.appVersion #or your app version appId = appName + " v" + appVersion if False: #For map only #outPath = appPath + "../../poaff/output/SIA/" #headFileName = "SIA@" outPath = appPath + "../../poaff/output/Tests/" headFileName = "BPa-Test4Clean@" else: outPath = appPath + "../out/" headFileName = "" srcPath = outPath refPath = outPath + "referentials/" logFile = outPath + "_" + appName + ".log" bpaTools.createFolder(outPath) #Init dossier de sortie oLog = bpaTools.Logger(appId, logFile) oLog.resetFile()
try: import bpaTools except ImportError: ### Include local modules/librairies ## import os import sys module_dir = os.path.dirname(__file__) aixmParserLocalSrc = "../../aixmParser/src/" sys.path.append(os.path.join(module_dir, aixmParserLocalSrc)) import bpaTools from frenchConfig import * ### Context applicatif #### appName = bpaTools.getFileName(__file__) appPath = bpaTools.getFilePath(__file__) appVersion = bpaTools.getVersionFile() appId = appName + " v" + appVersion inpPath = appPath + "../input/" outPath = appPath + "../output/" logFile = outPath + "_" + appName + ".log" def createGeoJsonFile(sFileSrc, sCountryName, sCountryCode, sCountryIsoCode, sCountryDepCode, oArea, iIdx=-1) -> None: if iIdx==-1: sName = sCountryName elif iIdx>-1 and sCountryName=="France": sName = oFranceNames.get(str(iIdx), str(iIdx)) else: sName = str(iIdx)
#!/usr/bin/env python3 import sys import bpaTools import aixmReader ### Context applicatif bpaTools.ctrlPythonVersion() __AppName__ = bpaTools.getFileName(__file__) __AppPath__ = bpaTools.getFilePath(__file__) __AppVers__ = bpaTools.getVersionFile() ___AppId___ = __AppName__ + " v" + __AppVers__ __OutPath__ = __AppPath__ + "../out/" __LogFile__ = __OutPath__ + "_" + __AppName__ + ".log" bpaTools.createFolder(__OutPath__) #Init dossier de sortie def syntaxe(): print("Aeronautical Information Exchange Model (AIXM) Converter") print( "Call: " + __AppName__ + " <[drive:][path]filename> <Format> <Type> [<Type2> ... <TypeN>] [<Option(s)>]" ) print("With:") print(" <[drive:][path]filename> AIXM source file") print("") print(" <Format> - Output formats:") print(" " + aixmReader.CONST.frmtGEOJSON + " GeoJSON for GoogleMap") print(" " + aixmReader.CONST.frmtOPENAIR + " OpenAir for aeronautical software")