From c9edf5184168c25c3aed2d86bf56454648029c4d Mon Sep 17 00:00:00 2001 From: Maciek Borzecki Date: Thu, 15 Jan 2015 20:16:54 +0100 Subject: [PATCH] device: generate unique device string --- src/device.vala | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/device.vala b/src/device.vala index 2ce6586..69c99f7 100644 --- a/src/device.vala +++ b/src/device.vala @@ -18,6 +18,9 @@ * Maciek Borzecki */ +/** + * General device wrapper. + */ class Device : Object { public string device_id { get; private set; default = ""; } public string device_name { get; private set; default = ""; } @@ -47,8 +50,11 @@ class Device : Object { } + /** + * Generates a unique string for this device + */ public string to_unique_string() { - return ""; + return this.to_string().replace(" ", "-"); } public string to_string() {