Exemple #1
0
        /*
         * [WebMethod]
         * public string SaveResourceContents(ItemIdentifier itemId, string itemTypeName, Resource resource, string revisionAlias, string user, string pass)
         * {
         * //Auth login and IP
         * AuthorizeClient(user, pass);
         *
         * Type itemType = Type.GetType(itemTypeName);
         * if (!Core.Settings.disableBase64Encoding)
         * {
         *    resource.ResourceContents = Convert.FromBase64String(resource.ResourceAsBase64);
         *    resource.ResourceAsBase64 = string.Empty;
         * }
         *
         * string path = LocalRepo.SaveResourceContents(itemId, itemType, resource, revisionAlias);
         * return path;
         * }*/



        //�Private�Methods�(2)�
        private List <ExceptionProxy> createProxy(List <Exception> list)
        {
            List <ExceptionProxy> retval = new List <ExceptionProxy>();

            foreach (var e in list)
            {
                ExceptionProxy ep = new ExceptionProxy();
                ep.HelpLink   = e.HelpLink;
                ep.Message    = e.Message;
                ep.Source     = e.Source;
                ep.StackTrace = e.StackTrace;
                retval.Add(ep);
            }

            return(retval);
        }
Exemple #2
0
        /*
        [WebMethod]
        public string SaveResourceContents(ItemIdentifier itemId, string itemTypeName, Resource resource, string revisionAlias, string user, string pass)
        {
        //Auth login and IP
        AuthorizeClient(user, pass);

        Type itemType = Type.GetType(itemTypeName);
        if (!Core.Settings.disableBase64Encoding)
        {
            resource.ResourceContents = Convert.FromBase64String(resource.ResourceAsBase64);
            resource.ResourceAsBase64 = string.Empty;
        }

        string path = LocalRepo.SaveResourceContents(itemId, itemType, resource, revisionAlias);
        return path;
        }*/
        //�Private�Methods�(2)
        private List<ExceptionProxy> createProxy(List<Exception> list)
        {
            List<ExceptionProxy> retval = new List<ExceptionProxy>();

              foreach (var e in list) {
            ExceptionProxy ep = new ExceptionProxy();
            ep.HelpLink = e.HelpLink;
            ep.Message = e.Message;
            ep.Source = e.Source;
            ep.StackTrace = e.StackTrace;
            retval.Add(ep);
              }

              return retval;
        }