java-sdk
Runtime module for the Java SDK
Installation
dagger install github.com/lgtdio/dagger/sdk/java@736eabb66f8cbe32ecac21cd49d2696e41110084
Entrypoint
Return Type
JavaSdk !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
sdkSourceDir | Directory | - | Directory with the Java SDK source code. dagger-java-samples is not necessary to build, but as it's referenced in the root pom.xml maven will check if it's there. So we keep the pom.xml to fake it. |
Example
dagger -m github.com/lgtdio/dagger/sdk/java@736eabb66f8cbe32ecac21cd49d2696e41110084 call \
func (m *myModule) example() *JavaSdk {
return dag.
JavaSdk()
}
@function
def example() -> dag.JavaSdk:
return (
dag.java_sdk()
)
@func()
example(): JavaSdk {
return dag
.javaSdk()
}
Types
JavaSdk 🔗
sdksourceDir() 🔗
Return Type
Directory !
Example
dagger -m github.com/lgtdio/dagger/sdk/java@736eabb66f8cbe32ecac21cd49d2696e41110084 call \
sdksource-dir
func (m *myModule) example() *Directory {
return dag.
JavaSdk().
SdksourceDir()
}
@function
def example() -> dagger.Directory:
return (
dag.java_sdk()
.sdksource_dir()
)
@func()
example(): Directory {
return dag
.javaSdk()
.sdksourceDir()
}
requiredPaths() 🔗
Return Type
[String ! ] !
Example
dagger -m github.com/lgtdio/dagger/sdk/java@736eabb66f8cbe32ecac21cd49d2696e41110084 call \
required-paths
func (m *myModule) example(ctx context.Context) []string {
return dag.
JavaSdk().
RequiredPaths(ctx)
}
@function
async def example() -> List[str]:
return await (
dag.java_sdk()
.required_paths()
)
@func()
async example(): Promise<string[]> {
return dag
.javaSdk()
.requiredPaths()
}
codegen() 🔗
Return Type
GeneratedCode !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
modSource | ModuleSource ! | - | No description provided |
introspectionJson | File ! | - | No description provided |
Example
echo 'Custom types are not supported in shell examples'
func (m *myModule) example(modSource *ModuleSource, introspectionJson *File) *GeneratedCode {
return dag.
JavaSdk().
Codegen(modSource, introspectionJson)
}
@function
def example(mod_source: dag.ModuleSource, introspection_json: dagger.File) -> dag.GeneratedCode:
return (
dag.java_sdk()
.codegen(mod_source, introspection_json)
)
@func()
example(modSource: ModuleSource, introspectionJson: File): GeneratedCode {
return dag
.javaSdk()
.codegen(modSource, introspectionJson)
}
moduleRuntime() 🔗
Return Type
Container !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
modSource | ModuleSource ! | - | No description provided |
introspectionJson | File ! | - | No description provided |
Example
echo 'Custom types are not supported in shell examples'
func (m *myModule) example(modSource *ModuleSource, introspectionJson *File) *Container {
return dag.
JavaSdk().
ModuleRuntime(modSource, introspectionJson)
}
@function
def example(mod_source: dag.ModuleSource, introspection_json: dagger.File) -> dagger.Container:
return (
dag.java_sdk()
.module_runtime(mod_source, introspection_json)
)
@func()
example(modSource: ModuleSource, introspectionJson: File): Container {
return dag
.javaSdk()
.moduleRuntime(modSource, introspectionJson)
}