Top Description Fields Constructors Methods
org.apache.tools.ant.util

public Class Native2AsciiUtils

extends Object
Class Inheritance

Contains helper methods for Ant's built-in implementation of native2ascii.
Since
Ant 1.9.8

Field Summary

Modifier and TypeField and Description
private static final int

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public static String

Returns:

the translated line
ascii2native
(String
the input line
line
)

Replaces Unicode-Escapes.

public static String

Returns:

the translated line
native2ascii
(String
the input line
line
)

Replaces non-ASCII characters with their Unicode-Escapes.

private static int
tryParse(String line, int startIdx)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

MAX_ASCIIback to summary
private static final int MAX_ASCII

Constructor Detail

Native2AsciiUtilsback to summary
public Native2AsciiUtils()

Method Detail

ascii2nativeback to summary
public static String ascii2native(String line)

Replaces Unicode-Escapes.

Expects to be called once per line if applied to a file.

Parameters
line:String

the input line

Returns:String

the translated line

native2asciiback to summary
public static String native2ascii(String line)

Replaces non-ASCII characters with their Unicode-Escapes.

Expects to be called once per line if applied to a file.

Parameters
line:String

the input line

Returns:String

the translated line

tryParseback to summary
private static int tryParse(String line, int startIdx)