3 import tim.prune.correlate.AudioCorrelator;
4 import tim.prune.correlate.PhotoCorrelator;
5 import tim.prune.function.*;
6 import tim.prune.function.charts.Charter;
7 import tim.prune.function.compress.CompressTrackFunction;
8 import tim.prune.function.distance.DistanceFunction;
9 import tim.prune.function.edit.PointNameEditor;
10 import tim.prune.function.gpsies.GetGpsiesFunction;
11 import tim.prune.function.gpsies.UploadGpsiesFunction;
12 import tim.prune.function.srtm.LookupSrtmFunction;
13 import tim.prune.load.AudioLoader;
14 import tim.prune.load.BabelLoadFromFile;
15 import tim.prune.load.BabelLoadFromGps;
16 import tim.prune.save.GpsSaver;
17 import tim.prune.save.GpxExporter;
18 import tim.prune.save.KmlExporter;
19 import tim.prune.save.PovExporter;
20 import tim.prune.save.SvgExporter;
23 * Class to provide access to functions
25 public abstract class FunctionLibrary
27 public static GenericFunction FUNCTION_GPXEXPORT = null;
28 public static GenericFunction FUNCTION_KMLEXPORT = null;
29 public static PovExporter FUNCTION_POVEXPORT = null;
30 public static SvgExporter FUNCTION_SVGEXPORT = null;
31 public static GenericFunction FUNCTION_GPSLOAD = null;
32 public static GenericFunction FUNCTION_GPSSAVE = null;
33 public static GenericFunction FUNCTION_IMPORTBABEL = null;
34 public static GenericFunction FUNCTION_SAVECONFIG = null;
35 public static GenericFunction FUNCTION_EDIT_WAYPOINT_NAME = null;
36 public static RearrangeWaypointsFunction FUNCTION_REARRANGE_WAYPOINTS = null;
37 public static GenericFunction FUNCTION_REARRANGE_PHOTOS = null;
38 public static GenericFunction FUNCTION_COMPRESS = null;
39 public static GenericFunction FUNCTION_DELETE_RANGE = null;
40 public static GenericFunction FUNCTION_CROP_TRACK = null;
41 public static GenericFunction FUNCTION_INTERPOLATE = null;
42 public static GenericFunction FUNCTION_LOOKUP_SRTM = null;
43 public static GenericFunction FUNCTION_LOOKUP_WIKIPEDIA = null;
44 public static GenericFunction FUNCTION_SEARCH_WIKIPEDIA = null;
45 public static GenericFunction FUNCTION_DOWNLOAD_OSM = null;
46 public static GenericFunction FUNCTION_ADD_TIME_OFFSET = null;
47 public static GenericFunction FUNCTION_ADD_ALTITUDE_OFFSET = null;
48 public static GenericFunction FUNCTION_CONVERT_NAMES_TO_TIMES = null;
49 public static GenericFunction FUNCTION_DELETE_FIELD_VALUES = null;
50 public static GenericFunction FUNCTION_PASTE_COORDINATES = null;
51 public static GenericFunction FUNCTION_FIND_WAYPOINT = null;
52 public static GenericFunction FUNCTION_DUPLICATE_POINT = null;
53 public static GenericFunction FUNCTION_CONNECT_TO_POINT = null;
54 public static GenericFunction FUNCTION_DISCONNECT_PHOTO = null;
55 public static GenericFunction FUNCTION_REMOVE_PHOTO = null;
56 public static GenericFunction FUNCTION_DISCONNECT_AUDIO = null;
57 public static GenericFunction FUNCTION_CORRELATE_PHOTOS = null;
58 public static GenericFunction FUNCTION_ROTATE_PHOTO_LEFT = null;
59 public static GenericFunction FUNCTION_ROTATE_PHOTO_RIGHT = null;
60 public static GenericFunction FUNCTION_PHOTO_POPUP = null;
61 public static GenericFunction FUNCTION_IGNORE_EXIF_THUMB = null;
62 public static GenericFunction FUNCTION_CHARTS = null;
63 public static GenericFunction FUNCTION_3D = null;
64 public static GenericFunction FUNCTION_DISTANCES = null;
65 public static GenericFunction FUNCTION_FULL_RANGE_DETAILS = null;
66 public static GenericFunction FUNCTION_GET_GPSIES = null;
67 public static GenericFunction FUNCTION_UPLOAD_GPSIES = null;
68 public static GenericFunction FUNCTION_LOAD_AUDIO = null;
69 public static GenericFunction FUNCTION_REMOVE_AUDIO = null;
70 public static GenericFunction FUNCTION_CORRELATE_AUDIOS = null;
71 public static GenericFunction FUNCTION_PLAY_AUDIO = null;
72 public static GenericFunction FUNCTION_STOP_AUDIO = null;
73 public static GenericFunction FUNCTION_SET_MAP_BG = null;
74 public static GenericFunction FUNCTION_SET_DISK_CACHE = null;
75 public static GenericFunction FUNCTION_SET_PATHS = null;
76 public static GenericFunction FUNCTION_SET_KMZ_IMAGE_SIZE = null;
77 public static GenericFunction FUNCTION_SET_COLOURS = null;
78 public static GenericFunction FUNCTION_SET_LINE_WIDTH = null;
79 public static GenericFunction FUNCTION_SET_LANGUAGE = null;
80 public static GenericFunction FUNCTION_HELP = null;
81 public static GenericFunction FUNCTION_SHOW_KEYS = null;
82 public static GenericFunction FUNCTION_ABOUT = null;
83 public static GenericFunction FUNCTION_CHECK_VERSION = null;
87 * Initialise library of functions
88 * @param inApp App object to give to functions
90 public static void initialise(App inApp)
92 FUNCTION_GPXEXPORT = new GpxExporter(inApp);
93 FUNCTION_KMLEXPORT = new KmlExporter(inApp);
94 FUNCTION_POVEXPORT = new PovExporter(inApp);
95 FUNCTION_SVGEXPORT = new SvgExporter(inApp);
96 FUNCTION_GPSLOAD = new BabelLoadFromGps(inApp);
97 FUNCTION_GPSSAVE = new GpsSaver(inApp);
98 FUNCTION_IMPORTBABEL = new BabelLoadFromFile(inApp);
99 FUNCTION_SAVECONFIG = new SaveConfig(inApp);
100 FUNCTION_EDIT_WAYPOINT_NAME = new PointNameEditor(inApp);
101 FUNCTION_REARRANGE_WAYPOINTS = new RearrangeWaypointsFunction(inApp);
102 FUNCTION_REARRANGE_PHOTOS = new RearrangePhotosFunction(inApp);
103 FUNCTION_COMPRESS = new CompressTrackFunction(inApp);
104 FUNCTION_DELETE_RANGE = new DeleteSelectedRangeFunction(inApp);
105 FUNCTION_CROP_TRACK = new CropToSelection(inApp);
106 FUNCTION_INTERPOLATE = new InterpolateFunction(inApp);
107 FUNCTION_LOOKUP_SRTM = new LookupSrtmFunction(inApp);
108 FUNCTION_LOOKUP_WIKIPEDIA = new GetWikipediaFunction(inApp);
109 FUNCTION_SEARCH_WIKIPEDIA = new SearchWikipediaNames(inApp);
110 FUNCTION_DOWNLOAD_OSM = new DownloadOsmFunction(inApp);
111 FUNCTION_ADD_TIME_OFFSET = new AddTimeOffset(inApp);
112 FUNCTION_ADD_ALTITUDE_OFFSET = new AddAltitudeOffset(inApp);
113 FUNCTION_CONVERT_NAMES_TO_TIMES = new ConvertNamesToTimes(inApp);
114 FUNCTION_DELETE_FIELD_VALUES = new DeleteFieldValues(inApp);
115 FUNCTION_PASTE_COORDINATES = new PasteCoordinates(inApp);
116 FUNCTION_FIND_WAYPOINT = new FindWaypoint(inApp);
117 FUNCTION_DUPLICATE_POINT = new DuplicatePoint(inApp);
118 FUNCTION_CONNECT_TO_POINT = new ConnectToPointFunction(inApp);
119 FUNCTION_DISCONNECT_PHOTO = new DisconnectPhotoFunction(inApp);
120 FUNCTION_REMOVE_PHOTO = new RemovePhotoFunction(inApp);
121 FUNCTION_CORRELATE_PHOTOS = new PhotoCorrelator(inApp);
122 FUNCTION_ROTATE_PHOTO_LEFT = new RotatePhoto(inApp, false);
123 FUNCTION_ROTATE_PHOTO_RIGHT = new RotatePhoto(inApp, true);
124 FUNCTION_PHOTO_POPUP = new PhotoPopupFunction(inApp);
125 FUNCTION_IGNORE_EXIF_THUMB = new IgnoreExifThumb(inApp);
126 FUNCTION_CHARTS = new Charter(inApp);
127 FUNCTION_3D = new ShowThreeDFunction(inApp);
128 FUNCTION_DISTANCES = new DistanceFunction(inApp);
129 FUNCTION_FULL_RANGE_DETAILS = new FullRangeDetails(inApp);
130 FUNCTION_GET_GPSIES = new GetGpsiesFunction(inApp);
131 FUNCTION_UPLOAD_GPSIES = new UploadGpsiesFunction(inApp);
132 FUNCTION_LOAD_AUDIO = new AudioLoader(inApp);
133 FUNCTION_REMOVE_AUDIO = new RemoveAudioFunction(inApp);
134 FUNCTION_CORRELATE_AUDIOS = new AudioCorrelator(inApp);
135 FUNCTION_PLAY_AUDIO = new PlayAudioFunction(inApp);
136 FUNCTION_STOP_AUDIO = new StopAudioFunction(inApp);
137 FUNCTION_DISCONNECT_AUDIO = new DisconnectAudioFunction(inApp);
138 FUNCTION_SET_MAP_BG = new SetMapBgFunction(inApp);
139 FUNCTION_SET_DISK_CACHE = new DiskCacheConfig(inApp);
140 FUNCTION_SET_PATHS = new SetPathsFunction(inApp);
141 FUNCTION_SET_KMZ_IMAGE_SIZE = new SetKmzImageSize(inApp);
142 FUNCTION_SET_COLOURS = new SetColours(inApp);
143 FUNCTION_SET_LINE_WIDTH = new SetLineWidth(inApp);
144 FUNCTION_SET_LANGUAGE = new SetLanguage(inApp);
145 FUNCTION_HELP = new HelpScreen(inApp);
146 FUNCTION_SHOW_KEYS = new ShowKeysScreen(inApp);
147 FUNCTION_ABOUT = new AboutScreen(inApp);
148 FUNCTION_CHECK_VERSION= new CheckVersionScreen(inApp);