KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > jfun > parsec > ToReturn


1 /**
2  *
3  */

4 package jfun.parsec;
5
6 final class ToReturn<T> implements ToParser<T, T> {
7   private final String JavaDoc name;
8
9   ToReturn(String JavaDoc name) {
10     super();
11     this.name = name;
12   }
13
14   public Parser<T> toParser(T v) {
15     return Parsers.retn(name, v);
16   }
17 }
Popular Tags