annotate org/vamp_plugins/ParameterDescriptor.java @ 28:f2914a92b553

Docs
author Chris Cannam
date Mon, 19 Nov 2012 15:12:44 +0000
parents 7b1740a9020a
children c9515589be7d
rev   line source
Chris@3 1
Chris@3 2 package org.vamp_plugins;
Chris@3 3
Chris@28 4 /**
Chris@28 5 * ParameterDescriptor describes the properties of a configurable
Chris@28 6 * parameter of a Plugin.
Chris@28 7 */
Chris@3 8 public class ParameterDescriptor {
Chris@28 9
Chris@28 10 /**
Chris@28 11 * The name of the parameter, in computer-usable form. Will
Chris@28 12 * contain only the characters [a-zA-Z0-9_-].
Chris@28 13 */
Chris@3 14 public String identifier;
Chris@28 15
Chris@28 16 /**
Chris@28 17 * The human-readable name of the parameter.
Chris@28 18 */
Chris@3 19 public String name;
Chris@28 20
Chris@28 21 /**
Chris@28 22 * A human-readable short text describing the parameter. May be
Chris@28 23 * empty if the name has said it all already.
Chris@28 24 */
Chris@3 25 public String description;
Chris@28 26
Chris@28 27 /**
Chris@28 28 * The unit of the parameter, in human-readable form.
Chris@28 29 */
Chris@3 30 public String unit;
Chris@28 31
Chris@28 32 /**
Chris@28 33 * The minimum value of the parameter.
Chris@28 34 */
Chris@3 35 public float minValue;
Chris@28 36
Chris@28 37 /**
Chris@28 38 * The maximum value of the parameter.
Chris@28 39 */
Chris@3 40 public float maxValue;
Chris@28 41
Chris@28 42 /**
Chris@28 43 * The default value of the parameter. The plugin should
Chris@28 44 * ensure that parameters have this value on initialisation
Chris@28 45 * (i.e. the host is not required to explicitly set parameters
Chris@28 46 * if it wants to use their default values).
Chris@28 47 */
Chris@3 48 public float defaultValue;
Chris@28 49
Chris@28 50 /**
Chris@28 51 * True if the parameter values are quantized to a particular
Chris@28 52 * resolution.
Chris@28 53 */
Chris@3 54 public boolean isQuantized;
Chris@28 55
Chris@28 56 /**
Chris@28 57 * Quantization resolution of the parameter values (e.g. 1.0
Chris@28 58 * if they are all integers). Undefined if isQuantized is
Chris@28 59 * false.
Chris@28 60 */
Chris@3 61 public float quantizeStep;
Chris@28 62
Chris@28 63 /**
Chris@28 64 * Names for the quantized values. If isQuantized is true,
Chris@28 65 * this may either be empty or contain one string for each of
Chris@28 66 * the quantize steps from minValue up to maxValue inclusive.
Chris@28 67 * Undefined if isQuantized is false.
Chris@28 68 *
Chris@28 69 * If these names are provided, they should be shown to the
Chris@28 70 * user in preference to the values themselves. The user may
Chris@28 71 * never see the actual numeric values unless they are also
Chris@28 72 * encoded in the names.
Chris@28 73 */
Chris@3 74 public String[] valueNames;
Chris@3 75
Chris@3 76 ParameterDescriptor() {
Chris@3 77 minValue = 0;
Chris@3 78 maxValue = 0;
Chris@3 79 defaultValue = 0;
Chris@3 80 isQuantized = false;
Chris@3 81 }
Chris@3 82 }
Chris@3 83