--- /dev/null
+/*******************************************************************************\r
+ * Copyright (c) 2007, 2011 Association for Decentralized Information Management in\r
+ * Industry THTH ry.\r
+ * All rights reserved. This program and the accompanying materials\r
+ * are made available under the terms of the Eclipse Public License v1.0\r
+ * which accompanies this distribution, and is available at\r
+ * http://www.eclipse.org/legal/epl-v10.html\r
+ *\r
+ * Contributors:\r
+ * VTT Technical Research Centre of Finland - initial API and implementation\r
+ *******************************************************************************/\r
+package org.simantics.charts.query;\r
+\r
+import org.simantics.charts.ui.ChartAndSubscriptionItemDialog;\r
+import org.simantics.databoard.annotations.Optional;\r
+import org.simantics.databoard.util.Bean;\r
+import org.simantics.trend.configuration.Scale;\r
+import org.simantics.trend.configuration.TrendItem.DrawMode;\r
+\r
+/**\r
+ * This class wraps Chart Item and referenced Subscription Item data. \r
+ * \r
+ * @author toni.kalajainen\r
+ */\r
+public class ChartAndSubscriptionItemData extends Bean {\r
+\r
+ // Input\r
+ public int index;\r
+ @Optional public String chartName;\r
+ @Optional public String variableReference;\r
+ @Optional public String label;\r
+ @Optional public String[] subscriptions;\r
+ \r
+ public boolean binaryMode;\r
+ public boolean hasSubscriptionItem;\r
+ \r
+ /**\r
+ * Workaround: there's currently no proper support for modifying the following attributes\r
+ * <ul>\r
+ * <li>sampling interval</li>\r
+ * <li>deadband</li>\r
+ * </ul>\r
+ * on the fly so by default we simply do not allow it. Set this to\r
+ * <code>true</code> before opening {@link ChartAndSubscriptionItemDialog}\r
+ * to allow the user to edit the listed values.\r
+ */\r
+ public boolean mutableCollectionSettings = false;\r
+ \r
+ // Output\r
+ @Optional public String subscription = "Default";\r
+ @Optional public String unit = "";\r
+ @Optional public Double min, max, deadband, interval, gain, bias;\r
+ @Optional public DrawMode drawmode;\r
+ @Optional public Scale scale;\r
+\r
+ @Optional public Float strokeWidth;\r
+ @Optional public float[] color;\r
+\r
+}\r