/// <summary>
 ///     Constructor
 /// </summary>
 public HybridMainPage()
 {
     _instance = this;
     _syncContext = SynchronizationContext.Current;
     Task<BootConfig> task = Task.Run(() => BootConfig.GetBootConfig());
     _bootConfig = task.Result;
 }
Пример #2
0
        /// <summary>
        ///     Constructor
        /// </summary>
        public HybridMainPage()
        {
            _instance    = this;
            _syncContext = SynchronizationContext.Current;
            Task <BootConfig> task = Task.Run(() => BootConfig.GetBootConfig());

            _bootConfig = task.Result;
        }
 /// <summary>
 /// Constructor
 /// </summary>
 public PhoneHybridMainPage()
 {
     _instance = this;
     _syncContext = SynchronizationContext.Current;
     _bootConfig = BootConfig.GetBootConfig();
     _loginOptions = new LoginOptions("https://test.salesforce.com" /* FIXME once we have a server picker */,
         _bootConfig.ClientId, _bootConfig.CallbackURL, _bootConfig.Scopes);
     _clientManager = new ClientManager(_loginOptions);
 }
Пример #4
0
 // Return  the singleton instance (build it the first time it is called)
 public static BootConfig GetBootConfig()
 {
     if (_instance == null)
     {
         String configStr = ConfigHelper.ReadConfigFromResource(BOOTCONFIG_JSON);
         _instance = JsonConvert.DeserializeObject <BootConfig>(configStr);
     }
     return(_instance);
 }
        // Return  the singleton instance (build it the first time it is called)
        public static async Task <BootConfig> GetBootConfig()
        {
            if (_instance == null)
            {
                String configStr = await Extensions.Utilities.ReadFileFromApplicationAsync(BootConfigJson);

                _instance = JsonConvert.DeserializeObject <BootConfig>(configStr);
            }
            return(_instance);
        }
        // Return  the singleton instance (build it the first time it is called)
        public static async Task <BootConfig> GetBootConfig()
        {
            if (_instance == null)
            {
                String configStr = await ConfigHelper.ReadFileFromApplication(BOOTCONFIG_JSON);

                _instance = JsonConvert.DeserializeObject <BootConfig>(configStr);
            }
            return(_instance);
        }
 /// <summary>
 /// Constructor
 /// </summary>
 public HybridMainPage()
 {
     _instance = this;
     _syncContext = SynchronizationContext.Current;
     _bootConfig = BootConfig.GetBootConfig();
 }
 // Return  the singleton instance (build it the first time it is called)
 public static BootConfig GetBootConfig()
 {
     if (_instance == null)
     {
         String configStr = ConfigHelper.ReadConfigFromResource(BOOTCONFIG_JSON);
         _instance = JsonConvert.DeserializeObject<BootConfig>(configStr);
     }
     return _instance;
 }
 // Return  the singleton instance (build it the first time it is called)
 public static async Task<BootConfig> GetBootConfig()
 {
     if (_instance == null)
     {
         String configStr = await Extensions.Utilities.ReadFileFromApplicationAsync(BootConfigJson);
         _instance = JsonConvert.DeserializeObject<BootConfig>(configStr);
     }
     return _instance;
 }
 /// <summary>
 /// Constructor
 /// </summary>
 public HybridMainPage()
 {
     _instance    = this;
     _syncContext = SynchronizationContext.Current;
     _bootConfig  = BootConfig.GetBootConfig();
 }
 // Return  the singleton instance (build it the first time it is called)
 public static async Task<BootConfig> GetBootConfig()
 {
     if (_instance == null)
     {
         String configStr = await ConfigHelper.ReadFileFromApplication(BOOTCONFIG_JSON);
         _instance = JsonConvert.DeserializeObject<BootConfig>(configStr);
     }
     return _instance;
 }