summaryrefslogtreecommitdiff
path: root/vdrmanager/src
diff options
context:
space:
mode:
authorlado <herrlado@gmail.com>2011-10-26 14:53:33 +0200
committerlado <herrlado@gmail.com>2011-10-26 14:53:33 +0200
commitaa70e58f29c729adf3cdeb76af05e847736a0d19 (patch)
treeae0136b4d77b43b5b78ddf62cad8ad76943f0db2 /vdrmanager/src
parent488931f9325f5da0a2f2be01c1513836a9302793 (diff)
downloadvdr-manager-aa70e58f29c729adf3cdeb76af05e847736a0d19.tar.gz
vdr-manager-aa70e58f29c729adf3cdeb76af05e847736a0d19.tar.bz2
mapSpecialChars
Diffstat (limited to 'vdrmanager/src')
-rw-r--r--vdrmanager/src/de/bjusystems/vdrmanager/data/Recording.java17
1 files changed, 11 insertions, 6 deletions
diff --git a/vdrmanager/src/de/bjusystems/vdrmanager/data/Recording.java b/vdrmanager/src/de/bjusystems/vdrmanager/data/Recording.java
index 75fe9af..378ec00 100644
--- a/vdrmanager/src/de/bjusystems/vdrmanager/data/Recording.java
+++ b/vdrmanager/src/de/bjusystems/vdrmanager/data/Recording.java
@@ -3,19 +3,24 @@ package de.bjusystems.vdrmanager.data;
import java.util.Date;
+import de.bjusystems.vdrmanager.StringUtils;
+import de.bjusystems.vdrmanager.app.C;
+
+import static de.bjusystems.vdrmanager.gui.Utils.mapSpecialChars;
+
public class Recording extends BaseEvent{
public Recording(String line) {
- final String[] words = line.split(":");
+ final String[] words = StringUtils.splitPreserveAllTokens(line, C.DATA_SEPARATOR);
int idx = 0;
index = Integer.valueOf(words[idx++]);
start = new Date(Long.parseLong(words[idx++]) * 1000);
stop = new Date(Long.parseLong(words[idx++]) * 1000);
- channelName = words[idx++];
- title = words[idx++];
- shortText = words[idx++];
- description = words[idx++];
- fileName = words[idx++];
+ channelName = mapSpecialChars(words[idx++]);
+ title = mapSpecialChars(words[idx++]);
+ shortText = mapSpecialChars(words[idx++]);
+ description = mapSpecialChars(words[idx++]);
+ fileName = mapSpecialChars(words[idx++]);
fileSize = Integer.valueOf(words[idx++]);
}