Beispiel #1
0
        /// <summary>
        /// Restful Get function
        /// </summary>
        /// <typeparam name="TRsp">Result generic type</typeparam>
        /// <param name="api">Get api</param>
        /// <param name="jPath">Parse jParh for Response json</param>
        /// <returns></returns>
        public async static Task <PromiseResponse <TRsp> > Get <TRsp>(string api, params object[] jPath)
        {
            PromiseResponse <TRsp> response;

            try
            {
                response = await Networker.Get(api);

                return(response % jPath);
            }
            catch (Exception ex)
            {
                NetworkLog.ErrorLog?.Invoke(ex);
                return(ex);
            }
        }
Beispiel #2
0
 public static void Select()
 {
     Selection.activeObject = Networker.Get();
 }