An application of design patterns in the domain of language processing is presented. The target in this paper is a Java preprocessor which enables not only to add new features to Java language but also to rewrite existing Java programs. Making use of several design patterns including Reection Architectural Pattern, we successfully create a framework for language processing in Java. In particular we design and implement a core language extension of Java so that self-development and maintenance of the framework are p ossible. Several applications of the Java preprocessor and the framework are described, which include enumeration type denition, method t r acer, and generic type denition mechanism.