com.vgrs.xcode.cmdline.idna
Class NormalizeCmdLine

java.lang.Object
  extended by com.vgrs.xcode.cmdline.CmdLine
      extended by com.vgrs.xcode.cmdline.idna.NormalizeCmdLine

public class NormalizeCmdLine
extends CmdLine

Normalize the input sequence using the NFKC algorithm.

Usage: com.vgrs.xcode.cmdline.idna.NormalizeCmdLine [-c] file=[file name]

When the -c option is specified, the input should be 5 fields delimited by a ';'. The conformance test is applied as follows:

c4 == NFKC(c1) == NFKC(c2) == NFKC(c3) == NFKC(c4) == NFKC(c5)

where c1 is the first field, c2 is the second field, etc. A sample line is shown below:

1E0A;1E0A;0044 0307;1E0A;0044 0307;

Version:
1.0 Aug 16, 2010
Author:
nchigurupati

Field Summary
 
Fields inherited from class com.vgrs.xcode.cmdline.CmdLine
SWITCH_FILE
 
Constructor Summary
NormalizeCmdLine(java.lang.String[] args)
           
 
Method Summary
 java.lang.String getUsageOptions()
           
static void main(java.lang.String[] args)
          If the -c option has been specified the normalized input is checked for conformance.
static void testConformance(java.io.File input)
          File containing data in the specified format to test for conformance.
static void testConformance(java.lang.String input)
          Test the given input for conformance
static void testExecute(java.io.File input)
          Normalize the data in the given input file.
static void testExecute(java.lang.String input)
          Normalize the Unicode code points given in the input
 
Methods inherited from class com.vgrs.xcode.cmdline.CmdLine
getCommandName, getOptions, setCommandName, setOptions, showUsage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NormalizeCmdLine

public NormalizeCmdLine(java.lang.String[] args)
Parameters:
args - the command line arguments.
Method Detail

main

public static void main(java.lang.String[] args)
If the -c option has been specified the normalized input is checked for conformance.

Parameters:
args - the command line arguments.

testExecute

public static void testExecute(java.io.File input)
Normalize the data in the given input file.

Parameters:
input - file containing the data to be normalized.

testExecute

public static void testExecute(java.lang.String input)
                        throws XcodeException
Normalize the Unicode code points given in the input

Parameters:
input - the input to be normalized.
Throws:
XcodeException

testConformance

public static void testConformance(java.io.File input)
File containing data in the specified format to test for conformance.

Parameters:
input - the file containing the input to be normalized and tested for conformance.

testConformance

public static void testConformance(java.lang.String input)
Test the given input for conformance

Parameters:
input - Input to be tested for conformance

getUsageOptions

public java.lang.String getUsageOptions()
Specified by:
getUsageOptions in class CmdLine
Returns:
the usage of this command line class.


Copyright © 2000-2010 VeriSign Inc. All Rights Reserved