public class RenderingCLI extends java.lang.Object implements CLIModule
Modifier and Type | Class and Description |
---|---|
private static class |
RenderingCLI.Option |
(package private) static class |
RenderingCLI.RenderingArea
Data class to hold return values for
determineRenderingArea(DataSet) . |
Modifier and Type | Field and Description |
---|---|
private LatLon |
argAnchor |
private Bounds |
argBounds |
private boolean |
argDebug |
private java.lang.Double |
argHeightM |
private java.lang.Integer |
argHeightPx |
private java.lang.String |
argInput |
private java.lang.Integer |
argMaxImageSize |
private java.lang.String |
argOutput |
private java.lang.String |
argProjection |
private java.lang.Double |
argScale |
private java.util.List<RenderingHelper.StyleData> |
argStyles |
private boolean |
argTrace |
private java.lang.Double |
argWidthM |
private java.lang.Integer |
argWidthPx |
private java.lang.Integer |
argZoom |
private static int |
DEFAULT_MAX_IMAGE_SIZE |
static RenderingCLI |
INSTANCE
The singleton instance of this class.
|
private static double |
PIXEL_PER_METER |
Constructor and Description |
---|
RenderingCLI() |
Modifier and Type | Method and Description |
---|---|
private void |
checkPreconditions(RenderingHelper rh) |
(package private) RenderingCLI.RenderingArea |
determineRenderingArea(DataSet ds)
Find the area to render and the scale, given certain command line options and the dataset.
|
java.lang.String |
getActionKeyword()
Get the action keyword that the user needs to provide as first command
line argument to invoke this module.
|
private static java.lang.String |
getHelp() |
private java.util.logging.Level |
getLogLevel() |
(package private) void |
initialize()
Initialization.
|
private DataSet |
loadDataset() |
(package private) void |
parseArguments(java.lang.String[] argArray)
Parse command line arguments and do some low-level error checking.
|
void |
processArguments(java.lang.String[] argArray)
Process the remaining command line arguments and run any of the requested actions.
|
static void |
showHelp()
Displays help on the console
|
private void |
writeImageToFile(java.awt.image.BufferedImage image) |
public static final RenderingCLI INSTANCE
private static final double PIXEL_PER_METER
private static final int DEFAULT_MAX_IMAGE_SIZE
private boolean argDebug
private boolean argTrace
private java.lang.String argInput
private java.lang.String argOutput
private java.util.List<RenderingHelper.StyleData> argStyles
private java.lang.Integer argZoom
private java.lang.Double argScale
private java.lang.Double argWidthM
private java.lang.Double argHeightM
private java.lang.Integer argWidthPx
private java.lang.Integer argHeightPx
private java.lang.String argProjection
private java.lang.Integer argMaxImageSize
RenderingCLI()
public java.lang.String getActionKeyword()
CLIModule
getActionKeyword
in interface CLIModule
public void processArguments(java.lang.String[] argArray)
CLIModule
processArguments
in interface CLIModule
argArray
- command line arguments without the initial action keywordvoid parseArguments(java.lang.String[] argArray)
argArray
- the arguments arraypublic static void showHelp()
private static java.lang.String getHelp()
void initialize()
parseArguments(java.lang.String[])
).private java.util.logging.Level getLogLevel()
RenderingCLI.RenderingArea determineRenderingArea(DataSet ds)
ds
- the datasetprivate DataSet loadDataset() throws java.io.IOException, IllegalDataException
java.io.IOException
IllegalDataException
private void checkPreconditions(RenderingHelper rh)
private void writeImageToFile(java.awt.image.BufferedImage image) throws java.io.IOException
java.io.IOException