import { Injectable } from '@angular/core';

/*
  Generated class for the ShareProvider provider.

  See https://angular.io/guide/dependency-injection for more info on providers
  and Angular DI.
*/
@Injectable()
export class ShareService {

  devices: any;
  authToken: string;
  rootDevice: any;

  constructor() {
    this.devices = {};
    this.authToken = '';
    this.rootDevice = undefined;
  }

  setDevices(devices) {
    this.devices = devices;
  }

  getDevices() {
    return this.devices;
  }

  setAuthToken(authToken) {
    this.authToken = authToken;
  }

  getAuthToken() {
    return this.authToken;
  }

  setRootDevice(rootDevice) {
    this.rootDevice = rootDevice;
  }

  getRootDevice() {
    return this.rootDevice;
  }

}
