public class MLEnvironmentFactory extends Object
The following code snippet shows how to interact with MLEnvironmentFactory.
long mlEnvId = MLEnvironmentFactory.getNewMLEnvironmentId();
MLEnvironment mlEnv = MLEnvironmentFactory.get(mlEnvId);
| 限定符和类型 | 字段和说明 |
|---|---|
static Long |
DEFAULT_ML_ENVIRONMENT_ID
The default MLEnvironmentId.
|
| 构造器和说明 |
|---|
MLEnvironmentFactory() |
| 限定符和类型 | 方法和说明 |
|---|---|
static MLEnvironment |
get(Long mlEnvId)
Get the MLEnvironment using a MLEnvironmentId.
|
static MLEnvironment |
getDefault()
Get the MLEnvironment use the default MLEnvironmentId.
|
static Long |
getNewMLEnvironmentId()
Create a unique MLEnvironment id and register a new MLEnvironment in the factory.
|
static Long |
registerMLEnvironment(MLEnvironment env)
Register a new MLEnvironment to the factory and return a new MLEnvironment id.
|
static MLEnvironment |
remove(Long mlEnvId)
Remove the MLEnvironment using the MLEnvironmentId.
|
public static final Long DEFAULT_ML_ENVIRONMENT_ID
public static MLEnvironment get(Long mlEnvId)
mlEnvId - the MLEnvironmentIdpublic static MLEnvironment getDefault()
public static Long getNewMLEnvironmentId()
public static Long registerMLEnvironment(MLEnvironment env)
env - the MLEnvironment that will be stored in the factory.public static MLEnvironment remove(Long mlEnvId)
mlEnvId - the id.Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.