aboutsummaryrefslogtreecommitdiffstats
path: root/src/org/thialfihar/android/apg/DataSource.java
diff options
context:
space:
mode:
authorThialfihar <thialfihar@gmail.com>2010-12-25 14:00:25 +0000
committerThialfihar <thialfihar@gmail.com>2010-12-25 14:00:25 +0000
commit428cf39ba39314a193bc70930ca45317c4543404 (patch)
treeb8a4e76983f92e310f1f6d81d7fd339fd0d54fa8 /src/org/thialfihar/android/apg/DataSource.java
parent01889c405fd733c6a55eb7c9ef1f188b4cc95637 (diff)
downloadopen-keychain-428cf39ba39314a193bc70930ca45317c4543404.tar.gz
open-keychain-428cf39ba39314a193bc70930ca45317c4543404.tar.bz2
open-keychain-428cf39ba39314a193bc70930ca45317c4543404.zip
added an Intent and functionality to generate detached signatures
Diffstat (limited to 'src/org/thialfihar/android/apg/DataSource.java')
-rw-r--r--src/org/thialfihar/android/apg/DataSource.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/org/thialfihar/android/apg/DataSource.java b/src/org/thialfihar/android/apg/DataSource.java
index 3ad1d0b07..4ce5c5f7b 100644
--- a/src/org/thialfihar/android/apg/DataSource.java
+++ b/src/org/thialfihar/android/apg/DataSource.java
@@ -36,10 +36,20 @@ public class DataSource {
public void setText(String text) {
mText = text;
+ mData = null;
}
public void setData(byte[] data) {
mData = data;
+ mText = null;
+ }
+
+ public boolean isText() {
+ return mText != null;
+ }
+
+ public boolean isBinary() {
+ return mData != null;
}
public InputData getInputData(Context context, boolean withSize)