01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: *
17: * $Header:$
18: */
19: package org.apache.beehive.controls.runtime.generator;
20:
21: import java.io.IOException;
22: import java.util.List;
23:
24: import com.sun.mirror.apt.Filer;
25:
26: /**
27: * The Generator interface will be implemented by APT data types that result in the generation
28: * of new source or text artifacts.
29: * for template usage on class-type objects
30: * <p>
31: * This is done with an abstract class (instead of an interface) so derived abstract classes
32: * can be subclassed from it w/out requiring all of the methods to be declared there.
33: */
34: public interface Generator {
35: /**
36: * Returns the list of fully qualified class names for types that are derived
37: * from this Generator
38: */
39: public String[] getGeneratedTypes();
40:
41: /**
42: * Returns the list of generated files derived from this Generator during the
43: * check phase of annotation processing.
44: */
45: public List<GeneratorOutput> getCheckOutput(Filer filer)
46: throws IOException;
47:
48: /**
49: * Returns the list of generated files derived from this Generator during the
50: * generate phase of annotation processing.
51: */
52: public List<GeneratorOutput> getGenerateOutput(Filer filer)
53: throws IOException;
54: }
|