aboutsummaryrefslogtreecommitdiff
path: root/builder-model
diff options
context:
space:
mode:
authorXavier Ducrohet <xav@android.com>2013-06-21 19:27:56 -0700
committerXavier Ducrohet <xav@android.com>2013-06-29 14:38:13 -0700
commit60a5b2383dc6c67f85edfdf0d0fd33db6ec9e715 (patch)
treeaec6a9184f3ae9e59756883a30f8c0c57306c906 /builder-model
parent6dd1c8675adeaaa58cd0e9a8bc1fb779bd8fd331 (diff)
downloadbuild-60a5b2383dc6c67f85edfdf0d0fd33db6ec9e715.tar.gz
Improve model.
Since we are already changing the model in non compatible way, now is a good time to fix some issues. Refactoring all the properties of an artifact out of variant and into its own ArtifactInfo class, so that we can have both the main and test artifact in the variant in an elegant way. Also adding SigningConfig info to enable the creation of export wizard from the IDE. Change-Id: Ib6c48873ba0e5c5a61bc1e79b00a90e2be83652f
Diffstat (limited to 'builder-model')
-rw-r--r--builder-model/src/main/java/com/android/builder/model/AaptOptions.java34
-rw-r--r--builder-model/src/main/java/com/android/builder/model/SigningConfig.java48
2 files changed, 82 insertions, 0 deletions
diff --git a/builder-model/src/main/java/com/android/builder/model/AaptOptions.java b/builder-model/src/main/java/com/android/builder/model/AaptOptions.java
new file mode 100644
index 0000000..86192e0
--- /dev/null
+++ b/builder-model/src/main/java/com/android/builder/model/AaptOptions.java
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2012 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.builder.model;
+
+import java.util.List;
+
+/**
+ * Options for aapt.
+ */
+public interface AaptOptions {
+ /**
+ * Returns the value for the --ignore-assets option, or null
+ */
+ String getIgnoreAssets();
+
+ /**
+ * Returns the list of values for the -0 (disabled compression) option, or null
+ */
+ List<String> getNoCompress();
+}
diff --git a/builder-model/src/main/java/com/android/builder/model/SigningConfig.java b/builder-model/src/main/java/com/android/builder/model/SigningConfig.java
new file mode 100644
index 0000000..ebfb7e0
--- /dev/null
+++ b/builder-model/src/main/java/com/android/builder/model/SigningConfig.java
@@ -0,0 +1,48 @@
+/*
+ * Copyright (C) 2013 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.builder.model;
+
+import com.android.annotations.NonNull;
+import com.android.annotations.Nullable;
+
+import java.io.File;
+
+/**
+ * A Signing Configuration
+ */
+public interface SigningConfig {
+
+ @NonNull
+ public String getName();
+
+ @Nullable
+ File getStoreFile();
+
+ @Nullable
+ String getStorePassword();
+
+ @Nullable
+ String getKeyAlias();
+
+ @Nullable
+ String getKeyPassword();
+
+ @Nullable
+ String getStoreType();
+
+ boolean isSigningReady();
+}