Search in sources :

Example 21 with StringParameterValue

use of au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue in project constellation by constellation-app.

the class GetRecordStore method createParameters.

@Override
public PluginParameters createParameters() {
    final PluginParameters parameters = new PluginParameters();
    final PluginParameter<StringParameterValue> graphIdParam = StringParameterType.build(GRAPH_ID_PARAMETER_ID);
    graphIdParam.setName("Graph id");
    graphIdParam.setDescription("The id of a graph to get data from. (Default is the active graph)");
    parameters.addParameter(graphIdParam);
    final PluginParameter<BooleanParameterValue> selectedParam = BooleanParameterType.build(SELECTED_PARAMETER_ID);
    selectedParam.setName("Selected elements only");
    selectedParam.setDescription("If false (the default), return all elements, else return only the selected elements.");
    selectedParam.setObjectValue(false);
    parameters.addParameter(selectedParam);
    final PluginParameter<BooleanParameterValue> vxParam = BooleanParameterType.build(VX_PARAMETER_ID);
    vxParam.setName("Vertices only");
    vxParam.setDescription("If true, return vertices only (default false).");
    vxParam.setObjectValue(false);
    parameters.addParameter(vxParam);
    final PluginParameter<BooleanParameterValue> txParam = BooleanParameterType.build(TX_PARAMETER_ID);
    txParam.setName("Transactions only");
    txParam.setDescription("If true, return transactions only (default false).");
    txParam.setObjectValue(false);
    parameters.addParameter(txParam);
    final PluginParameter<StringParameterValue> attrsParam = StringParameterType.build(ATTRS_PARAMETER_ID);
    attrsParam.setName("Attribute list");
    attrsParam.setDescription("Include only these comma-separated attributes in the recordstore. Use this for much greater efficiency. (optional)");
    parameters.addParameter(attrsParam);
    return parameters;
}
Also used : BooleanParameterValue(au.gov.asd.tac.constellation.plugins.parameters.types.BooleanParameterType.BooleanParameterValue) StringParameterValue(au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue) PluginParameters(au.gov.asd.tac.constellation.plugins.parameters.PluginParameters)

Example 22 with StringParameterValue

use of au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue in project constellation by constellation-app.

the class GetTypeDescription method createParameters.

@Override
public PluginParameters createParameters() {
    final PluginParameters parameters = new PluginParameters();
    final PluginParameter<StringParameterValue> nameParam = StringParameterType.build(TYPE_PARAMETER_ID);
    nameParam.setName("The name of the type.");
    nameParam.setDescription("The name of the Node or Transaction type.");
    nameParam.setRequired(true);
    parameters.addParameter(nameParam);
    return parameters;
}
Also used : StringParameterValue(au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue) PluginParameters(au.gov.asd.tac.constellation.plugins.parameters.PluginParameters)

Example 23 with StringParameterValue

use of au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue in project constellation by constellation-app.

the class GetAttributes method createParameters.

@Override
public PluginParameters createParameters() {
    final PluginParameters parameters = new PluginParameters();
    final PluginParameter<StringParameterValue> graphIdParam = StringParameterType.build(GRAPH_ID_PARAMETER_ID);
    graphIdParam.setName("Graph id");
    graphIdParam.setDescription("The id of the graph to get the attributes of. (Default is the active graph)");
    parameters.addParameter(graphIdParam);
    return parameters;
}
Also used : StringParameterValue(au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue) PluginParameters(au.gov.asd.tac.constellation.plugins.parameters.PluginParameters)

Example 24 with StringParameterValue

use of au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue in project constellation by constellation-app.

the class RunPlugin method createParameters.

@Override
public PluginParameters createParameters() {
    final PluginParameters parameters = new PluginParameters();
    final PluginParameter<StringParameterValue> nameParam = StringParameterType.build(PLUGIN_NAME_PARAMETER_ID);
    nameParam.setName("Plugin name");
    nameParam.setDescription("The name of the plugin to run.");
    nameParam.setRequired(true);
    parameters.addParameter(nameParam);
    final PluginParameter<StringParameterValue> graphIdParam = StringParameterType.build(GRAPH_ID_PARAMETER_ID);
    graphIdParam.setName("Graph id");
    graphIdParam.setDescription("The id of a graph to run the plugin on. (Default is the active graph)");
    parameters.addParameter(graphIdParam);
    final PluginParameter<StringParameterValue> argsParam = StringParameterType.build(ARGS_PARAMETER_ID);
    argsParam.setName("Plugin arguments (body)");
    argsParam.setDescription("A JSON object containing parameter names and values to be passed to the plugin.");
    argsParam.setRequestBodyExampleJson("#/components/examples/runPluginExample");
    parameters.addParameter(argsParam);
    return parameters;
}
Also used : StringParameterValue(au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue) PluginParameters(au.gov.asd.tac.constellation.plugins.parameters.PluginParameters)

Example 25 with StringParameterValue

use of au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue in project constellation by constellation-app.

the class CreateTransactionTypePlugin method createParameters.

@Override
public PluginParameters createParameters() {
    final PluginParameters params = new PluginParameters();
    final PluginParameter<StringParameterValue> nameParam = StringParameterType.build(NAME_PARAMETER_ID);
    nameParam.setName("Name");
    nameParam.setDescription("The name of the new transaction type");
    nameParam.setStringValue(null);
    params.addParameter(nameParam);
    final PluginParameter<StringParameterValue> descriptionParam = StringParameterType.build(DESCRIPTION_PARAMETER_ID);
    descriptionParam.setName("Description");
    descriptionParam.setDescription("The description of the new transaction type");
    descriptionParam.setStringValue(null);
    params.addParameter(descriptionParam);
    final PluginParameter<ColorParameterType.ColorParameterValue> colorParam = ColorParameterType.build(COLOR_PARAMETER_ID);
    colorParam.setName("Color");
    colorParam.setDescription("The color of the new transaction type");
    colorParam.setStringValue(ConstellationColor.RED.getName());
    params.addParameter(colorParam);
    final PluginParameter<StringParameterValue> lineStyleParam = StringParameterType.build(LINE_STYLE_PARAMETER_ID);
    lineStyleParam.setName("Line Style");
    lineStyleParam.setDescription("The line style of the new transaction type");
    lineStyleParam.setStringValue(LineStyle.SOLID.toString());
    params.addParameter(lineStyleParam);
    final PluginParameter<BooleanParameterType.BooleanParameterValue> directedParam = BooleanParameterType.build(DIRECTED_PARAMETER_ID);
    directedParam.setName("Directed");
    directedParam.setDescription("Is the transaction directed?");
    directedParam.setBooleanValue(true);
    params.addParameter(directedParam);
    final PluginParameter<StringParameterValue> superTypeParam = StringParameterType.build(SUPER_TYPE_PARAMETER_ID);
    superTypeParam.setName("Super Type");
    superTypeParam.setDescription("The name of the super type of the new transaction type");
    superTypeParam.setStringValue(null);
    params.addParameter(superTypeParam);
    final PluginParameter<StringParameterValue> overriddenTypeParam = StringParameterType.build(OVERRIDDEN_TYPE_PARAMETER_ID);
    overriddenTypeParam.setName("Overridden Type");
    overriddenTypeParam.setDescription("The name of the overridden type of the new transaction type");
    overriddenTypeParam.setStringValue(null);
    params.addParameter(overriddenTypeParam);
    final PluginParameter<BooleanParameterType.BooleanParameterValue> incompleteParam = BooleanParameterType.build(INCOMPLETE_PARAMETER_ID);
    incompleteParam.setName("Incomplete");
    incompleteParam.setDescription("Is the new transaction type incomplete?");
    incompleteParam.setBooleanValue(false);
    params.addParameter(incompleteParam);
    return params;
}
Also used : StringParameterValue(au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue) PluginParameters(au.gov.asd.tac.constellation.plugins.parameters.PluginParameters)

Aggregations

PluginParameters (au.gov.asd.tac.constellation.plugins.parameters.PluginParameters)50 StringParameterValue (au.gov.asd.tac.constellation.plugins.parameters.types.StringParameterValue)50 BooleanParameterValue (au.gov.asd.tac.constellation.plugins.parameters.types.BooleanParameterType.BooleanParameterValue)13 SingleChoiceParameterValue (au.gov.asd.tac.constellation.plugins.parameters.types.SingleChoiceParameterType.SingleChoiceParameterValue)9 PluginParameter (au.gov.asd.tac.constellation.plugins.parameters.PluginParameter)6 ObjectParameterValue (au.gov.asd.tac.constellation.plugins.parameters.types.ObjectParameterType.ObjectParameterValue)5 ArrayList (java.util.ArrayList)5 Map (java.util.Map)5 ParameterChange (au.gov.asd.tac.constellation.plugins.parameters.ParameterChange)3 IntegerParameterValue (au.gov.asd.tac.constellation.plugins.parameters.types.IntegerParameterType.IntegerParameterValue)3 Graph (au.gov.asd.tac.constellation.graph.Graph)2 ColorParameterValue (au.gov.asd.tac.constellation.plugins.parameters.types.ColorParameterType.ColorParameterValue)2 NbPreferences (org.openide.util.NbPreferences)2 GraphElementType (au.gov.asd.tac.constellation.graph.GraphElementType)1 GraphReadMethods (au.gov.asd.tac.constellation.graph.GraphReadMethods)1 GraphWriteMethods (au.gov.asd.tac.constellation.graph.GraphWriteMethods)1 ReadableGraph (au.gov.asd.tac.constellation.graph.ReadableGraph)1 StoreGraph (au.gov.asd.tac.constellation.graph.StoreGraph)1 GraphDataObject (au.gov.asd.tac.constellation.graph.file.GraphDataObject)1 GraphObjectUtilities (au.gov.asd.tac.constellation.graph.file.GraphObjectUtilities)1