FileDocCategorySizeDatePackage
RegexSplit.javaAPI DocExample507Mon May 06 19:21:08 BST 2002com.ronsoft.books.nio.regex

RegexSplit

public class RegexSplit extends Object
Test regex splitting. Remember to quote the input args.
author
Ron Hitchens
version
$Id: RegexSplit.java,v 1.1 2002/05/07 02:21:08 ron Exp $

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] argv)

		Pattern spacePat = Pattern.compile ("\\s+");
		String [] tokens = spacePat.split (argv [0]);

		for (int i = 0; i < tokens.length; i++) {
			System.out.println ("" + i + ": " + tokens [i]);
		}