5fb45284c161dd44495cadf50536254ffb1059e1
[smartthings-infrastructure.git] / MobilePresence / MobilePresences.groovy
1 //Create a class for mobile presence
2 package MobilePresence
3 import SmartThing.SmartThings
4
5 public class MobilePresences extends SmartThings {
6         List mobilePresences = new ArrayList()
7         
8         MobilePresences(Closure sendEvent) {
9                 // Only initialize one time since we only have one device for each capability
10                 mobilePresences = smartThings
11
12                 // Initialization
13                 String id = "mobileDeviceID0"
14                 String label = "mobileDevice"
15                 String displayName = "mobileDevice"
16                 String deviceNetworkId = "id58323"
17
18                 mobilePresences.add(new MobilePresence(sendEvent, id, label, displayName, deviceNetworkId))
19         }
20 }