Class Arguments

  • Direct Known Subclasses:
    Arguments

    public class Arguments
    extends java.lang.Object
    This class is responsible for parsing the command line arguments to the compiler. To add new arguments to the compiler, this class must be extended and the parseOtherArgs method overridden.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      float corbaLevel
      -corba [level] option, where [level] is a floating-point number indicating the maximal level of CORBA IDL the parser framework can accept.
      boolean cppModule
      <f46082.46.01> True if new module entries are created for each re-opened module.
      java.util.Hashtable<java.lang.String,​java.lang.String> definedSymbols
      A table of defined symbols.
      boolean emitAll
      If this is true, then the types in all included files are also emitted.
      java.lang.String file
      The name of the IDL file.
      java.util.Vector<java.lang.String> includePaths
      A list of strings, each of which is a path from which included files are found.
      boolean keepOldFiles
      If this is true, then existing files should not be overwritten by the compiler.
      boolean noWarn
      -noWarn option.
      boolean scannerDebugFlag  
      boolean tokenDebugFlag  
      boolean verbose
      True if the user wishes to see processing remarks.
      boolean versionRequest
      -version option.
    • Constructor Summary

      Constructors 
      Constructor Description
      Arguments()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private void addIncludePaths​(java.util.Properties props)  
      (package private) void parseArgs​(java.lang.String[] args)
      Collect the command-line parameters.
      protected void parseOtherArgs​(java.lang.String[] args, java.util.Properties properties)
      Method parseOtherArgs() is called when the framework detects arguments which are unknown to it.
      protected void setDebugFlags​(java.lang.String args)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • file

        public java.lang.String file
        The name of the IDL file.
      • verbose

        public boolean verbose
        True if the user wishes to see processing remarks.
      • keepOldFiles

        public boolean keepOldFiles
        If this is true, then existing files should not be overwritten by the compiler.
      • emitAll

        public boolean emitAll
        If this is true, then the types in all included files are also emitted.
      • includePaths

        public java.util.Vector<java.lang.String> includePaths
        A list of strings, each of which is a path from which included files are found.
      • definedSymbols

        public java.util.Hashtable<java.lang.String,​java.lang.String> definedSymbols
        A table of defined symbols. The key is the symbol name; the value (if any) is the replacement value for the symbol.
      • cppModule

        public boolean cppModule
        <f46082.46.01> True if new module entries are created for each re-opened module.
      • versionRequest

        public boolean versionRequest
        -version option.
      • corbaLevel

        public float corbaLevel
        -corba [level] option, where [level] is a floating-point number indicating the maximal level of CORBA IDL the parser framework can accept.
      • noWarn

        public boolean noWarn
        -noWarn option. Suppress warnings when true.
      • scannerDebugFlag

        public boolean scannerDebugFlag
      • tokenDebugFlag

        public boolean tokenDebugFlag
    • Constructor Detail

      • Arguments

        public Arguments()
    • Method Detail

      • parseOtherArgs

        protected void parseOtherArgs​(java.lang.String[] args,
                                      java.util.Properties properties)
                               throws InvalidArgument
        Method parseOtherArgs() is called when the framework detects arguments which are unknown to it. The default implementation of this method simply throws an InvalidArgument exception. Any overriding implementation must check the arguments passed to it for validity and process the arguments appropriately. If it detects an invalid argument, it should throw an InvalidArgument exception. Arguments MUST be of the form `/<arg> [<qualifiers>]' or `-<arg> [<qualifiers>]' where <qualifiers> is optional (for example, -iC:\includes, `C:\includes' is the qualifier for the argument `i').
        Parameters:
        args - The arguments which are unknown by the framework.
        properties - Environment-style properties collected from the file idl.config.
        Throws:
        InvalidArgument - if the argument is unknown.
      • setDebugFlags

        protected void setDebugFlags​(java.lang.String args)
      • parseArgs

        void parseArgs​(java.lang.String[] args)
                throws InvalidArgument
        Collect the command-line parameters.
        Parameters:
        args - arguments passed in
        Throws:
        InvalidArgument
      • addIncludePaths

        private void addIncludePaths​(java.util.Properties props)