public class StubGenerator extends Object
A stub file can be used to add annotations to methods of classes, that are only available in binary or the source of which cannot be edited.
Constructor and Description |
---|
StubGenerator()
Constructs a
StubGenerator that outputs to System.out . |
StubGenerator(OutputStream out)
Constructs a
StubGenerator that outputs to the provided output stream. |
StubGenerator(PrintStream out)
Constructs a
StubGenerator that outputs to the provided output stream. |
Modifier and Type | Method and Description |
---|---|
static void |
main(String[] args)
The main entry point to StubGenerator.
|
void |
stubFromField(Element elt)
Generate the stub file for all the classes within the provided package.
|
void |
stubFromMethod(Element elt)
Generate the stub file for all the classes within the provided package.
|
void |
stubFromPackage(PackageElement packageElement)
Generate the stub file for all the classes within the provided package.
|
void |
stubFromType(TypeElement typeElement)
Generate the stub file for provided class.
|
public StubGenerator()
StubGenerator
that outputs to System.out
.public StubGenerator(PrintStream out)
StubGenerator
that outputs to the provided output stream.out
- the output streampublic StubGenerator(OutputStream out)
StubGenerator
that outputs to the provided output stream.out
- the output streampublic void stubFromField(Element elt)
public void stubFromPackage(PackageElement packageElement)
public void stubFromMethod(Element elt)
public void stubFromType(TypeElement typeElement)
public static void main(String[] args)
args
- command-line arguments