public class JIPipeDynamicParameterCollection extends Object implements JIPipeCustomParameterCollection, JIPipeValidatable, JsonDeserializable, JIPipeCustomTextDescriptionParameter
Modifier and Type | Class and Description |
---|---|
static class |
JIPipeDynamicParameterCollection.BeforeAddParameterEvent |
static class |
JIPipeDynamicParameterCollection.BeforeAddParameterEventEmitter |
static interface |
JIPipeDynamicParameterCollection.BeforeAddParameterEventListener |
static class |
JIPipeDynamicParameterCollection.Deserializer |
static class |
JIPipeDynamicParameterCollection.UserParameterDefinition
Parameter definition by a user
|
JIPipeParameterCollection.ParameterChangedEvent, JIPipeParameterCollection.ParameterChangedEventEmitter, JIPipeParameterCollection.ParameterChangedEventListener, JIPipeParameterCollection.ParameterStructureChangedEvent, JIPipeParameterCollection.ParameterStructureChangedEventEmitter, JIPipeParameterCollection.ParameterStructureChangedEventListener, JIPipeParameterCollection.ParameterUIChangedEvent, JIPipeParameterCollection.ParameterUIChangedEventEmitter, JIPipeParameterCollection.ParameterUIChangedEventListener
Constructor and Description |
---|
JIPipeDynamicParameterCollection() |
JIPipeDynamicParameterCollection(boolean allowUserModification)
Creates a new instance.
|
JIPipeDynamicParameterCollection(boolean allowUserModification,
Class<?>[] allowedTypes)
Creates a new instance
|
JIPipeDynamicParameterCollection(boolean allowUserModification,
Set<JIPipeParameterTypeInfo> allowedTypes)
Creates a new instance
|
JIPipeDynamicParameterCollection(JIPipeDynamicParameterCollection other)
Copies the parameters from the original
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getChildParameterCollections, getIncludeReflectionParameters
deserializeFromJsonNode, emitParameterChangedEvent, emitParameterStructureChangedEvent, emitParameterUIChangedEvent, getContextActions, getParameter, getParameterAccess, installUIOverrideParameterEditor, installUIParameterOptions, isParameterUIVisible, isParameterUIVisible, serializeToJsonFile, serializeToJsonGenerator, serializeToJsonString, setParameter
generateValidityReport
getTextDescriptionOf
public JIPipeDynamicParameterCollection()
public JIPipeDynamicParameterCollection(boolean allowUserModification)
allowUserModification
- let user modify this collectionpublic JIPipeDynamicParameterCollection(JIPipeDynamicParameterCollection other)
other
- The originalpublic JIPipeDynamicParameterCollection(boolean allowUserModification, Set<JIPipeParameterTypeInfo> allowedTypes)
allowUserModification
- let user modify this collectionallowedTypes
- The parameter types that can be added by the user (ignored if user cannot add).public JIPipeDynamicParameterCollection(boolean allowUserModification, Class<?>[] allowedTypes)
allowUserModification
- let user modify this collectionallowedTypes
- The parameter types that can be added by the user (ignored if user cannot add).public JIPipeDynamicParameterCollection.BeforeAddParameterEventEmitter getBeforeAddParameterEventEmitter()
public JIPipeParameterCollection.ParameterChangedEventEmitter getParameterChangedEventEmitter()
JIPipeParameterCollection
getParameterChangedEventEmitter
in interface JIPipeParameterCollection
public JIPipeParameterCollection.ParameterStructureChangedEventEmitter getParameterStructureChangedEventEmitter()
JIPipeParameterCollection
getParameterStructureChangedEventEmitter
in interface JIPipeParameterCollection
public JIPipeParameterCollection.ParameterUIChangedEventEmitter getParameterUIChangedEventEmitter()
JIPipeParameterCollection
getParameterUIChangedEventEmitter
in interface JIPipeParameterCollection
public Map<String,JIPipeParameterAccess> getParameters()
JIPipeCustomParameterCollection
getParameters
in interface JIPipeCustomParameterCollection
JIPipeParameterAccess
.getKey()public JIPipeMutableParameterAccess addParameter(JIPipeMutableParameterAccess parameterAccess)
parameterAccess
- the parameterpublic boolean supportsAllParameterTypes()
public JIPipeMutableParameterAccess addParameter(String key, Class<?> fieldClass)
key
- A unique keyfieldClass
- The parameter classpublic void clear()
public void removeParameter(String key)
key
- The parameter keypublic JIPipeMutableParameterAccess getParameter(String key)
key
- The parameter keypublic <T> T getValue(String key, Class<T> klass)
T
- The parameter typekey
- The parameter keyklass
- The returned typepublic <T> boolean setValue(String key, T value)
T
- The parameter typekey
- The parameter keyvalue
- The parameter valuepublic void setAllowedTypes(Set<Class<?>> allowedTypes)
allowedTypes
- Parameter typespublic void fromJson(com.fasterxml.jackson.databind.JsonNode node)
fromJson
in interface JsonDeserializable
node
- JSON datapublic boolean isAllowUserModification()
public void setAllowUserModification(boolean allowUserModification)
allowUserModification
- True if modification is allowedpublic boolean containsKey(String key)
key
- the parameter keypublic JIPipeParameterAccess get(String key)
key
- the parameter keypublic void beginModificationBlock()
JIPipeParameterCollection.ParameterStructureChangedEvent
until endModificationBlock() is called.
Use this method for many changes at oncepublic void endModificationBlock()
JIPipeParameterCollection.ParameterStructureChangedEvent
public void copyTo(JIPipeDynamicParameterCollection target)
target
- the target configurationpublic void reportValidity(JIPipeValidationReportContext reportContext, JIPipeValidationReport report)
JIPipeValidatable
reportValidity
in interface JIPipeValidatable
reportContext
- the report contextreport
- the report to be added topublic Function<JIPipeDynamicParameterCollection.UserParameterDefinition,JIPipeMutableParameterAccess> getInstanceGenerator()
public void setInstanceGenerator(Function<JIPipeDynamicParameterCollection.UserParameterDefinition,JIPipeMutableParameterAccess> instanceGenerator)
public JIPipeMutableParameterAccess addParameter(String key, Class<?> fieldClass, String name, String description, Annotation... annotations)
public String getTextDescription()
JIPipeCustomTextDescriptionParameter
getTextDescription
in interface JIPipeCustomTextDescriptionParameter
Copyright © 2020–2025 Leibniz Institute for Natural Product Research and Infection Biology - Hans Knöll Institute (HKI). All rights reserved.