Browse Source

device: generate unique device string

bboozzoo/device-cache
Maciek Borzecki 10 years ago
parent
commit
c9edf51841
1 changed files with 7 additions and 1 deletions
  1. +7
    -1
      src/device.vala

+ 7
- 1
src/device.vala View File

@ -18,6 +18,9 @@
* Maciek Borzecki <maciek.borzecki (at] gmail.com>
*/
/**
* 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() {


Loading…
Cancel
Save