CADI.Server
Class ServerParser

java.lang.Object
  extended by CADI.Common.Util.ArgumentsParser
      extended by CADI.Server.ServerParser

public class ServerParser
extends ArgumentsParser

Arguments parser for CADI server

Version:
1.0.5 2009/05/02
Author:
Group on Interactive Coding of Images (GICI)

Field Summary
private  java.lang.String cacheDirectory
           
private  int cordType
           
private  int cpiType
           
private  int deliveryProgressionOrder
           
private  boolean independentMessageHeaders
           
private  int keepAliveTimeout
           
private  boolean logEnabled
           
private  java.lang.String logFile
           
private  int logLevel
           
private  float maxRate
           
private  int numThreads
           
private  int[] ports
           
private  int rateDistortionMethod
           
private  java.lang.String[][] serverArguments
           
private  java.lang.String targetsPath
           
private  boolean XMLLogFormat
           
 
Constructor Summary
ServerParser(java.lang.String[] arguments)
          Receives program arguments and parses it, setting to arguments variables.
 
Method Summary
 java.lang.String getCacheDirectory()
           
 int getCoRDType()
           
 int getCPIType()
           
 int getDeliveryProgressionOrder()
           
 boolean getIndependentMessageHeaders()
           
 int getKeepAliveTimeout()
           
 java.lang.String getLogFile()
           
 int getLogLevel()
           
 float getMaxRate()
           
 int getNumThreads()
           
 int[] getPorts()
           
 int getRateDistortionMethod()
           
 java.lang.String getTargetsPath()
           
 boolean isLogEnabled()
           
 boolean isXMLLogFormat()
           
 void parseArgument(int argFound, java.lang.String[] options)
          Parse an argument using parse functions from super class and put its value/s to the desired variable.
private  void printCopyright()
          Prints out the copyright.
private  void printLiability()
          Prints out the liability.
private  void printWarranty()
          Prints out the warranty.
 
Methods inherited from class CADI.Common.Util.ArgumentsParser
parse, parseBoolean, parseBooleanArray, parseFloatArray, parseFloatArray, parseFloatPositive, parseIntegerArray, parseIntegerArray, parseIntegerPositive, parseIntegerRangesArray, parseLongArray, parseLongArray, parseLongPositive, parseString, showArgsInfo, showArgsInfoLatexTable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serverArguments

private java.lang.String[][] serverArguments

ports

private int[] ports

numThreads

private int numThreads

targetsPath

private java.lang.String targetsPath

logFile

private java.lang.String logFile

XMLLogFormat

private boolean XMLLogFormat

logEnabled

private boolean logEnabled

logLevel

private int logLevel

cacheDirectory

private java.lang.String cacheDirectory

rateDistortionMethod

private int rateDistortionMethod

cpiType

private int cpiType

cordType

private int cordType

deliveryProgressionOrder

private int deliveryProgressionOrder

keepAliveTimeout

private int keepAliveTimeout

maxRate

private float maxRate

independentMessageHeaders

private boolean independentMessageHeaders
Constructor Detail

ServerParser

public ServerParser(java.lang.String[] arguments)
             throws ParameterException,
                    ErrorException
Receives program arguments and parses it, setting to arguments variables.

Parameters:
arguments - the array of strings passed at the command line
Throws:
ParameterException - when an invalid parsing is detected
ErrorException - when some problem with method invocation occurs
Method Detail

parseArgument

public void parseArgument(int argFound,
                          java.lang.String[] options)
                   throws ParameterException
Parse an argument using parse functions from super class and put its value/s to the desired variable. This function is called from parse function of the super class.

Parameters:
argFound - number of parameter (the index of the array coderArguments)
options - the command line options of the argument
Throws:
ParameterException - when some error about parameters passed (type, number of params, etc.) occurs

getPorts

public int[] getPorts()

getNumThreads

public int getNumThreads()

getTargetsPath

public java.lang.String getTargetsPath()

getLogFile

public java.lang.String getLogFile()

isXMLLogFormat

public boolean isXMLLogFormat()

isLogEnabled

public boolean isLogEnabled()

getLogLevel

public int getLogLevel()

getRateDistortionMethod

public int getRateDistortionMethod()

getCPIType

public int getCPIType()

getCoRDType

public int getCoRDType()

getDeliveryProgressionOrder

public int getDeliveryProgressionOrder()

getCacheDirectory

public java.lang.String getCacheDirectory()

getKeepAliveTimeout

public int getKeepAliveTimeout()

getMaxRate

public float getMaxRate()

getIndependentMessageHeaders

public boolean getIndependentMessageHeaders()

printWarranty

private void printWarranty()
Prints out the warranty.


printLiability

private void printLiability()
Prints out the liability.


printCopyright

private void printCopyright()
Prints out the copyright.



CADI - Copyright (C) 2007
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

Group on Interactive Coding of Images (GICI) (contact)