Search:
Login
Preferences
Help/Guide
About Trac
Register
Forgot your password?
Wiki
Timeline
Changelog
Browse Source
View Tickets
New Ticket
Roadmap
Builds
Sonar
Search
Context Navigation
+0
Start Page
Index
History
Editing El:Help/CommandLineOptions
Adjust edit area height:
8
12
16
20
24
28
32
36
40
Edit side-by-side
[[TranslatedPages(revision=47)]] [[PageOutline(2)]] = Επιλογές Γραμμής Εντολών = Τέσσερις τύποι επιλογών γραμμής εντολών επηρεάζουν το JOSM: * Τα [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#Programarguments επιχειρήματα Προγράμματος⤓] (Program arguments) ελέγχουν άμεσα το JOSM. Ονομάζονται ''args'' από την Java. * Οι [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#Javaoptions επιλογές Java⤓] επηρεάζουν το περιβάλλον του (JVM) και μερικές φορές ονομάζονται ''VM arguments''. * Οι [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#run-options επιλογές Run⤓] εμπλέκονται στο WebStart. Μερικές είναι για διάγνωση και εισαγωγή. * Μερικές [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#Otheroptions Άλλες επιλογές⤓] για βοηθητικά προγράμματα. {{{ #!sh # Running a jar java [Java options] -jar josm.jar [Program arguments] # Launch a Web Start javaws [Run-options] -J[Java option] josm.jnlp }}} Η [wikitr:/Help/Action/ShowStatusReport Αναφορά Κατάστασης] από το μενού Βοήθεια εμφανίζει τα τρέχοντα επιχειρήματα προγράμματος και τις επιλογές Java. Μερικά [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#Examples παραδείγματα⤓] και για τα δύο αυτά εμφανίζονται παρακάτω. **Σημείωση:** Ο όρος {{{josm.jar}}} είναι μια κοινή συντομογραφία για τα ονόματα αρχείων ''josm-tested.jar'' και ''josm-latest.jar''. Ο όρος ''josm.jnlp'' αναφέρεται επίσης στο ''josm-latest.jnlp''. Όπως συνήθως, τα επιχειρήματα στη γραμμή εντολών διαχωρίζονται μεταξύ τους με κενά. == Επιχειρήματα προγράμματος για το JOSM ==#Programarguments Το πρώτο επιχείρημα μπορεί να είναι μια **εντολή** για το JOSM ώστε να λειτουργεί αυτόνομα. Οι εντολές που χρησιμοποιούνται συνήθως ως προεπιλογή είναι: `render`, `project` ή `runjosm`. Τα υπόλοιπα επιχειρήματα είναι **επιλογές** για το JOSM. Μπορεί να είναι URLs, ονόματα αρχείων, συντεταγμένες, απλές επιλογές ή ζεύγη επιλογή=τιμή. Οι επιλογές για την εντολή runjosm παρατίθενται παρακάτω. Στο τέλος βρίσκονται οι επιλογές για τις εντολές [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#Programargumentsrendering render⤓] και [https://josm.openstreetmap.de/wiki/El%3AHelp/CommandLineOptions#Programargumentsprojection project⤓]. {{{ usage: java -jar josm.jar [<command>] <options>... commands: runjosm launch JOSM (default, performed when no command is specified) render render data and save the result to an image file project convert coordinates from one coordinate reference system to another validate validate data For details on the render and project commands, run them with the --help option. The remainder of this help page documents the runjosm command. options: --help|-h Show this help --geometry=widthxheight(+|-)x(+|-)y Standard unix geometry argument [--download=]minlat,minlon,maxlat,maxlon Download the bounding box [--download=]<URL> Download the location at the URL (with lat=x&lon=y&zoom=z) [--download=]<filename> Open a file (any file type that can be opened with File/Open) --downloadgps=minlat,minlon,maxlat,maxlon Download the bounding box as raw GPS --downloadgps=<URL> Download the location at the URL (with lat=x&lon=y&zoom=z) as raw GPS --selection=<searchstring> Select with the given search --[no-]maximize Launch in maximized mode --reset-preferences Reset the preferences to default --load-preferences=<url-to-xml> Changes preferences according to the XML file --set=<key>=<value> Set preference key to value --language=<language> Set the language --version Displays the JOSM version and exits --status-report Show status report with useful information that can be attached to bugs --debug Print debugging messages to console --skip-plugins Skip loading plugins --offline=<OSM_API|JOSM_WEBSITE|CACHE_UPDATES|CERTIFICATES|ALL> Disable access to the given resource(s), separated by comma <OSM API|JOSM website|Cache updates|Certificates|All> }}} Το μέρος `--download=` ης επιλογής λήψης είναι προαιρετικό. Τα επιχειρήματα `--download`, `--downloadgps` και `--selection` επεξεργάζονται με αυτήν τη σειρά. Η τιμή `<url-to-xml>` μπορεί να δείχνει σε τοπικό αρχείο με μορφή `file:relative/path/name.xml`. Τα στοιχεία στην τιμή της επιλογής `--offline` διαχωρίζονται με κόμμα. == Επιλογές Java ==#Javaoptions Ελέγχουν τη Java Virtual Machine [https://docs.oracle.com/javase/8/docs/technotes/tools/unix/java.html (JVM)] και μπορούν να ορίσουν [https://docs.oracle.com/javase/tutorial/essential/environment/sysprop.html ιδιότητες ] εντός αυτής. Το JOSM διαβάζει κάποιες από αυτές απευθείας, όπως το `josm.home`. Άλλες, όπως η`user.language` και `user.country` επηρεάζουν τις προεπιλεγμένες ρυθμίσεις της JVM, οι οποίες με τη σειρά τους επηρεάζουν και το JOSM. {{{ Java system properties options: -Djosm.dir.name=JOSM Change the JOSM directory name -Djosm.pref=/PATH/TO/JOSM/PREF Set the preferences directory Default (Linux XDG): /home/name/.config/JOSM Default (Windows): C:\Users\name\AppData\Roaming\JOSM -Djosm.userdata=/PATH/TO/JOSM/USERDATA Set the user data directory Default (Linux XDG): /home/name/.local/share/JOSM Default (Windows): C:\Users\name\AppData\Roaming\JOSM -Djosm.cache=/PATH/TO/JOSM/CACHE Set the cache directory Default (Linux XDG): /home/name/.cache/JOSM Default (Windows): C:\Users\name\AppData\Local\JOSM\cache -Djosm.home=/PATH/TO/JOSM/HOMEDIR Set the common directory for preferences, user data and ./cache/. Lower precedence. Will get overridden from specific setting. -Xmx...m Set maximum Java heap size in megabytes. May avoid Out-of-Memory errors. }}} Η επιλογή `-Xmx...m` μπορεί να είναι χρήσιμη όταν προκύπτουν σφάλματα [wikitr:/Download#Outofmemory Εκτός Μνήμης (Out of Memory)]. Αν ορίσετε έναν κοινό φάκελο με την ιδιότητα `Djosm.home` τότε το JOSM θα δημιουργήσει τους υποφακέλους ./autosave, ./cache και ./validator. Αν μια τιμή περιέχει κενά, πρέπει να την περικλείσετε σε εισαγωγικά, π.χ. `"josm dev"`. Όταν οι χαρακτήρες μη ASCII στη γραμμή εντολών εμφανίζονται λανθασμένα (μπερδεμένοι), χρησιμοποιήστε την επιλογή `-Dfile.encoding=Cp850` για να λαμβάνετε κείμενο από την Java σε άλλη [https://docs.oracle.com/javase/8/docs/technotes/guides/intl/encoding.doc.html σελίδα κώδικα]. Η [https://msdn.microsoft.com/de-de/library/windows/desktop/dd317756%28v=vs.85%29.aspx σελίδα κώδικα] που χρησιμοποιείται εμφανίζεται με την εντολή `chcp⏎` στο τερματικό. Για χρήση UTF-8 στα Windows, εκτελέστε πρώτα την εντολή `chcp 65001` στο παράθυρο του τερματικού των Windows πριν ξεκινήσετε το JOSM χρησιμοποιώντας το `java -Dfile.encoding=UTF-8 -jar josm.jar` Το πακέτο Debian του JOSM, `josm-latest` χρησιμοποιεί την επιλογή `-Djosm.dir.name=JOSM-latest` για να προσφέρει παράλληλες εγκαταστάσεις στους καταλόγους βάσης XDG. [=#Examples **Παραδείγματα για επιλογές JOSM runjosm και επιλογές Java**] {{{ #!sh # Load three files java -jar josm.jar track1.gpx BigBen.jpg "london data.osm" # Download from OSM according to an URL with zoom and coordinates java -jar josm.jar https://www.openstreetmap.org/#map=18/51.501/-0.124 # Download a bounding box and select every element matching a string java -jar josm.jar 51.500,-0.126,51.502,-0.122 --selection="Big Ben" # # Set directory for JOSM according to a property from the operating system java -Djosm.pref=$XDG_CONFIG_HOME -jar josm.jar # Quotations for a value with space and show JOSMs GUI in English java -Djosm.dir.name="josm dev" -jar josm.jar --language=en # Set the common directory in a sub-subdirectory below the active command prompt java -Djosm.home=biketour2017/london -jar josm.jar # More memory and without phoning home java -Xmx1024m --set=message.notifier.enabled=false -jar josm.jar # # Start in an English environment and log debug info plus messages from stderr java -Duser.language=en -jar josm.jar --debug 1>logfile.txt 2>&1 }}} == Επιλογές εκτέλεσης για το Java Web Start ==#run-options Οι επιλογές εκτέλεσης διαβάζονται από την εντολή `javaws`. Ελέγχουν τον μηχανισμό Web Start, μπορούν να περικλείουν επιλογές Java και να κάνουν διάγνωση της Java. {{{ #!sh # Control -offline Allows to Web Start JOSM without internet access # Encapsulate -J<java option> Supplies the <java option> to the JVM -J-Xmx1024m Here: Set maximum Java heap size to 1024 megabyte # Diagnosis javaws -viewer Shows the Cache Viewer in the Java Control Panel # Allows to opens the Java Control Panel from the command line. javaws -clearcache Removes all non-installed applications from the cache # Equal to 'Delete Files and Applications' from the 'Temporary File Settings' invoked # by the 'Settings' button in the 'General' tab of the Java Control Panel. # javaws -Xclearcache on OpenJDK }}} Η επιλογή εκτέλεσης `-J` βρίσκεται πίσω από το γράμμα J και το παρέχει ως επιλογή Java. Το αρχείο [wikitr:/Help/jnlpOptions jnlp-File] που χρησιμοποιείται από το [https://docs.oracle.com/javase/8/docs/technotes/tools/unix/javaws.html Web Start] προσφέρει έναν δεύτερο τρόπο να [https://docs.oracle.com/javase/8/docs/technotes/guides/javaws/developersguide/syntax.html ορίσετε επιλογές] για την JRE και για το πρόγραμμα JOSM απευθείας. Η εντολή `javaws` διαθέτει μερικές επιλογές ελέγχου σε όλα τα συστήματα. Η επιλογή `-clearcache` και η εκκαθάριση της προσωρινής μνήμης μέσω του Πίνακα Ελέγχου Java θα διαγράψουν τα εικονίδια που βασίζονται στο JNLP από την επιφάνεια εργασίας. Το εικονίδιο του JOSM θα αφαιρεθεί εάν είχε τοποθετηθεί ως αποτέλεσμα κλικ σε αρχείο jnlp μέσω προγράμματος περιήγησης. == Άλλες επιλογές ==#Otheroptions Ο Εκκινητής `josm.exe` γνωστός και ως [http://launch4j.sourceforge.net/docs.html#Runtime_options Launch4j] (μόνο σε [wikitr:/Download#Mswindowswrapper MS Windows]) μπορεί να παρέχει κάποιες πληροφορίες αποσφαλμάτωσης. {{{ #!sh josm.exe --j4l-debug Tries to write a launch4j.log to current directory josm.exe --j4l-dont-wait Ends the wrapper after invoking JOSM. }}} == Γραμμή εντολών για το Render και Project == === Επιχειρήματα προγράμματος για το rendering του JOSM ===#Programargumentsrendering {{{ Usage: java -jar josm.jar render <options> Description: Renders data and saves the result to an image file. Options: --help|-h Show this help --input|-i <file> Input data file name (.osm) --output|-o <file> Output image file name (.png); defaults to 'out.png' --style|-s <file> Style file to use for rendering (.mapcss or .zip) This option can be repeated to load multiple styles. --setting <key>:<value> Style setting (in JOSM accessible in the style list dialogue right click menu) Applies to the last style loaded with the --style option. --zoom|-z <lvl> Select zoom level to render. (integer value, 0=entire earth, 18=street level) --scale <scale> Select the map scale A value of 10000 denotes a scale of 1:10000 (1 cm on the map equals 100 m on the ground; display resolution: 96 dpi) Options --zoom and --scale are mutually exclusive. --bounds|-b auto|<min_lon>,<min_lat>,<max_lon>,<max_lat> Area to render, default value is 'auto' With keyword 'auto', the downloaded area in the .osm input file will be used (if recorded). --anchor <lon>,<lat> Specify bottom left corner of the rendering area Used in combination with width and height options to determine the area to render. --width-m <number> Width of the rendered area, in meter --height-m <number> Height of the rendered area, in metres --width-px <number> Width of the target image, in pixels --height-px <number> Height of the target image, in pixels --projection <code> Projection to use, default value 'epsg:3857' (web-Mercator) --max-image-size <number> Maximum image width/height in pixel ('0' means no limit), default value: 20000 To specify the rendered area and scale, the options can be combined in various ways: * --bounds (--zoom|--scale|--width-px|--height-px) * --anchor (--width-m|--width-px) (--height-m|--height-px) (--zoom|--scale) * --anchor --width-m --height-m (--width-px|--height-px) * --anchor --width-px --height-px (--width-m|--height-m) If neither 'bounds' nor 'anchor' is given, the default value --bounds=auto takes effect and the bounds of the download area in the .osm input file are used. Examples: java -jar josm.jar render -i data.osm -s style.mapcss -z 16 josm render -i data.osm -s style.mapcss --scale 5000 josm render -i data.osm -s style.mapcss -z 16 -o image.png josm render -i data.osm -s elemstyles.mapcss --setting hide_icons:false -z 16 josm render -i data.osm -s style.mapcss -s another_style.mapcss -z 16 -o image.png josm render -i data.osm -s style.mapcss --bounds 21.151,51.401,21.152,51.402 -z 16 josm render -i data.osm -s style.mapcss --anchor 21.151,51.401 --width-m 500 --height-m 300 -z 16 josm render -i data.osm -s style.mapcss --anchor 21.151,51.401 --width-m 500 --height-m 300 --width-px 1800 josm render -i data.osm -s style.mapcss --scale 5000 --projection epsg:4326 }}} === Επιχειρήματα προγράμματος για την προβολή του JOSM ===#Programargumentsprojection {{{ Usage: java -jar josm.jar project <options> <crs> +to <crs> [file] Description: Converts coordinates from one coordinate reference system to another. Options: --help|-h Show this help -I Switch input and output crs -r Switch order of input coordinates (east/north, lon/lat) -s Switch order of output coordinates (east/north, lon/lat) <crs>: The format for input and output coordinate reference system is similar to that of the PROJ.4 software. [file]: Reads input data from one or more files listed as positional arguments. When no files are given, or the filename is "-", data is read from standard input. Examples: java -jar josm.jar project +init=epsg:4326 +to +init=epsg:3857 <<<"11.232274 50.5685716" => 1250371.1334500168 6545331.055189664 java -jar josm.jar project +proj=lonlat +datum=WGS84 +to +proj=merc +a=6378137 +b=6378137 +nadgrids=@null <<EOF 11d13'56.19"E 50d34'6.86"N 118d39'30.42"W 37d20'18.76"N EOF => 1250371.1334500168 6545331.055189664 -1.3208998232319113E7 4486401.160664663 }}} == Δείτε επίσης == * [wikitr:/Download#Troubleshooting Αντιμετώπιση Προβλημάτων Java] * [wikitr:/InstallNotes Σημειώσεις Εγκατάστασης] * [wikitr:/Help/Preferences Προτιμήσεις] - Επισκόπηση Προτιμήσεων ---- Πίσω στη [wikitr:/Help Βασική Βοήθεια]
Note:
See
WikiFormatting
and
TracWiki
for help on editing wiki content.
Change information
Your email or username:
E-mail address and name can be saved in the
Preferences
Comment about this change (optional):
Note:
See
TracWiki
for help on using the wiki.