Exemplo n.º 1
0
        public static Dictionary <string, ApplicationKey> MapFromJson(Dictionary <string, object> jsonMap)
        {
            Dictionary <string, ApplicationKey> result = new Dictionary <string, ApplicationKey>();

            foreach (var entry in jsonMap)
            {
                ApplicationKey value = CreateFromDictionary(entry.Value as Dictionary <string, object>);
                result.Add(entry.Key, value);
            }
            return(result);
        }
Exemplo n.º 2
0
        public static ApplicationKey CreateFromDictionary(Dictionary<string, object> jsonMap)
        {
            try
            {
                if (jsonMap == null)
                {
                    return null;
                }

                var request = new ApplicationKey();

                if(jsonMap.ContainsKey("stringValue"))
                {
                    request.StringValue = (string) jsonMap["stringValue"];
                }

                return request;
            }
            catch (System.ApplicationException ex)
            {
                throw new AmazonException("Error encountered while creating Object from dicionary", ex);
            }
        }
Exemplo n.º 3
0
        public static ApplicationKey CreateFromDictionary(Dictionary <string, object> jsonMap)
        {
            try
            {
                if (jsonMap == null)
                {
                    return(null);
                }

                var request = new ApplicationKey();


                if (jsonMap.ContainsKey("stringValue"))
                {
                    request.StringValue = (string)jsonMap["stringValue"];
                }

                return(request);
            }
            catch (System.ApplicationException ex)
            {
                throw new AmazonException("Error encountered while creating Object from dicionary", ex);
            }
        }
Exemplo n.º 4
0
 public override void SetApplicationKey(ApplicationKey applicationKey)
 {
     Start();
                     Jsonable.CheckForErrors(Json.Deserialize(SetApplicationKeyJson(applicationKey.ToJson())) as Dictionary<string, object>);
 }
Exemplo n.º 5
0
 // AmazonMobileAds API
 public abstract void SetApplicationKey(ApplicationKey applicationKey);
Exemplo n.º 6
0
 // AmazonMobileAds API
 public abstract void SetApplicationKey(ApplicationKey applicationKey);
Exemplo n.º 7
0
 public override void SetApplicationKey(ApplicationKey applicationKey)
 {
     Start();
     Jsonable.CheckForErrors(Json.Deserialize(SetApplicationKeyJson(applicationKey.ToJson())) as Dictionary <string, object>);
 }