src/main/java/de/unixwork/uwproj/OptionValue.java

changeset 0
38775db5fdf5
child 40
b42bfc9e9983
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/main/java/de/unixwork/uwproj/OptionValue.java	Mon Feb 04 15:09:39 2019 +0100
@@ -0,0 +1,57 @@
+/*
+ * To change this license header, choose License Headers in Project Properties.
+ * To change this template file, choose Tools | Templates
+ * and open the template in the editor.
+ */
+package de.unixwork.uwproj;
+
+import java.util.List;
+import java.util.LinkedList;
+
+/**
+ *
+ * @author olaf
+ */
+public class OptionValue {
+    Option option;
+    
+    String value;
+    
+    TargetData targetData = new TargetData();
+    
+    public OptionValue(Option opt) {
+        option = opt;
+    }
+
+    public String getValue() {
+        return value;
+    }
+
+    public void setValue(String value) {
+        this.value = value;
+    }
+
+    public List<String> getDependencies() {
+        return targetData.getDependencies();
+    }
+
+    public List<Define> getDefines() {
+        return targetData.getDefines();
+    }
+    
+    public void setTargetData(TargetData data) {
+        targetData = data;
+    }
+    
+    public String getFunc() {
+        return option.getValueFunc(value);
+    }
+    
+    public String getMake() {
+        return targetData.getMake();
+    }
+    
+    public boolean hasMake() {
+        return targetData.getMake().trim().length() > 0;
+    }
+}

mercurial