Class EmitterSpec
java.lang.Object
com.arc_e_tect.gradle.apionly.transcriberj.EmitterSpec
- All Implemented Interfaces:
org.gradle.api.Named
One emitter's configuration for one subscription: the
emitter('<id>') block.
apiOnlyTranscriberJ {
subscription('orders') {
emitter('restdocs') {
sourceSets = ['testContract', 'testContractWireMock']
options = [tests: 'true']
}
}
}
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.gradle.api.Named
org.gradle.api.Named.Namer -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract org.gradle.api.file.DirectoryPropertyWhere the emitter's files, which belong on no classpath, are generated.abstract org.gradle.api.file.DirectoryPropertyWhere the emitter's Java sources are generated.abstract org.gradle.api.file.DirectoryPropertyWhere the emitter's classpath resources are generated.getName()The emitter's id.The emitter's options, passed to it unchanged; what each means is the emitter's README's to say.abstract org.gradle.api.provider.ListProperty<String> The source sets the emitter's Java sources and classpath resources go to.
-
Constructor Details
-
EmitterSpec
Creates the block for one emitter.- Parameters:
id- the emitter's id, such asrestdocs
-
-
Method Details
-
getName
The emitter's id.- Specified by:
getNamein interfaceorg.gradle.api.Named- Returns:
- the id
-
getSourceSets
The source sets the emitter's Java sources and classpath resources go to. Each must be one of the subscription'ssourceSets, so that it sees the schema classes.Default: the subscription's
sourceSetsfor an emitter that writes Java or resources, and none for one that writes only files. An empty list is allowed only for the latter.- Returns:
- the source set names
-
getOptions
The emitter's options, passed to it unchanged; what each means is the emitter's README's to say.Default: none.
- Returns:
- the options
-
getIntoJava
public abstract org.gradle.api.file.DirectoryProperty getIntoJava()Where the emitter's Java sources are generated.Default:
build/generated/sources/transcriberj/<contract>/<id>.- Returns:
- the directory
-
getIntoResources
public abstract org.gradle.api.file.DirectoryProperty getIntoResources()Where the emitter's classpath resources are generated.Default:
build/generated/resources/transcriberj/<contract>/<id>.- Returns:
- the directory
-
getIntoFiles
public abstract org.gradle.api.file.DirectoryProperty getIntoFiles()Where the emitter's files, which belong on no classpath, are generated.Default:
build/generated/files/transcriberj/<contract>/<id>.- Returns:
- the directory
-