コード例 #1
0
ファイル: SvnStream.cs プロジェクト: softec/SubversionSharp
 private SvnStream(IntPtr ptr, SvnDelegate read, SvnDelegate write, SvnDelegate close)
 {
     mStream = ptr;
     mReadDelegate = read;
     mWriteDelegate = write;
     mCloseDelegate = close;
 }
コード例 #2
0
ファイル: SvnStream.cs プロジェクト: softec/SubversionSharp
 public SvnStream(IntPtr baton, AprPool pool)
 {
     mStream = Svn.svn_stream_create(baton, pool);
     mReadDelegate = null;
     mWriteDelegate = null;
     mCloseDelegate = null;
 }
コード例 #3
0
 private SvnStream(IntPtr ptr, SvnDelegate read, SvnDelegate write, SvnDelegate close)
 {
     mStream        = ptr;
     mReadDelegate  = read;
     mWriteDelegate = write;
     mCloseDelegate = close;
 }
コード例 #4
0
        public static int Status(SvnPath path,
                                 SvnOptRevision revision,
                                 SvnWcStatus.Func statusFunc, IntPtr statusBaton,
                                 bool descend, bool getAll, bool update, bool noIgnore,
                                 SvnClientContext ctx, AprPool pool)
        {
            int         rev;
            SvnDelegate statusDelegate = new SvnDelegate(statusFunc);

            Debug.Write(String.Format("svn_client_status({0},{1},{2},{3},{4:X},{5},{6},{7},{8},{9})...", path, revision, statusFunc.Method.Name, statusBaton.ToInt32(), descend, getAll, update, noIgnore, ctx, pool));
            SvnError err = Svn.svn_client_status(out rev, path, revision,
                                                 (Svn.svn_wc_status_func_t)statusDelegate.Wrapper,
                                                 statusBaton,
                                                 (descend ? 1 : 0), (getAll ? 1 : 0),
                                                 (update ? 1 : 0), (noIgnore ? 1 : 0),
                                                 ctx, pool);

            if (!err.IsNoError)
            {
                throw new SvnException(err);
            }
            Debug.WriteLine(String.Format("Done({0})", rev));
            if (update)
            {
                return(rev);
            }
            else
            {
                return(-1);
            }
        }
コード例 #5
0
 public SvnStream(IntPtr baton, AprPool pool)
 {
     mStream        = Svn.svn_stream_create(baton, pool);
     mReadDelegate  = null;
     mWriteDelegate = null;
     mCloseDelegate = null;
 }
コード例 #6
0
ファイル: SvnStream.cs プロジェクト: softec/SubversionSharp
 private SvnStream(IntPtr ptr)
 {
     mStream = ptr;
     mReadDelegate = null;
     mWriteDelegate = null;
     mCloseDelegate = null;
 }
コード例 #7
0
 private SvnStream(IntPtr ptr)
 {
     mStream        = ptr;
     mReadDelegate  = null;
     mWriteDelegate = null;
     mCloseDelegate = null;
 }
コード例 #8
0
 private SvnClientContext(svn_client_ctx_t *ptr)
 {
     mClientContext = ptr;
     mAuthBaton = new SvnAuthBaton();
     mNotifyFunc = SvnDelegate.NullFunc;
     mLogMsgFunc = SvnDelegate.NullFunc;
        		mCancelFunc = SvnDelegate.NullFunc;
 }
コード例 #9
0
 public SvnClientContext(IntPtr ptr)
 {
     mClientContext = (svn_client_ctx_t *)ptr.ToPointer();
     mAuthBaton     = new SvnAuthBaton();
     mNotifyFunc    = SvnDelegate.NullFunc;
     mLogMsgFunc    = SvnDelegate.NullFunc;
     mCancelFunc    = SvnDelegate.NullFunc;
 }
コード例 #10
0
 public SvnClientContext(IntPtr ptr)
 {
     mClientContext = (svn_client_ctx_t *) ptr.ToPointer();
     mAuthBaton = new SvnAuthBaton();
     mNotifyFunc = SvnDelegate.NullFunc;
     mLogMsgFunc = SvnDelegate.NullFunc;
        		mCancelFunc = SvnDelegate.NullFunc;
 }
コード例 #11
0
 private SvnClientContext(svn_client_ctx_t *ptr)
 {
     mClientContext = ptr;
     mAuthBaton     = new SvnAuthBaton();
     mNotifyFunc    = SvnDelegate.NullFunc;
     mLogMsgFunc    = SvnDelegate.NullFunc;
     mCancelFunc    = SvnDelegate.NullFunc;
 }
コード例 #12
0
        public static SvnAuthProviderObject GetPromptProvider(
            SslClientCertPwPrompt promptFunc,
            IntPtr promptBaton, int retryLimit, AprPool pool)
        {
            IntPtr      authObj;
            SvnDelegate auth = new SvnDelegate(promptFunc);

            Debug.Write(String.Format("svn_client_get_ssl_client_cert_pw_prompt_provider([callback:{0}],{1:X},{2},{3})...", promptFunc.Method.Name, promptBaton.ToInt32(), retryLimit, pool));
            Svn.svn_client_get_ssl_client_cert_pw_prompt_provider(out authObj,
                                                                  (Svn.svn_auth_ssl_client_cert_pw_prompt_func_t)auth.Wrapper,
                                                                  promptBaton, retryLimit, pool);
            Debug.WriteLine(String.Format("Done({0:X})", authObj.ToInt32()));
            return(new SvnAuthProviderObject(authObj, auth));
        }
コード例 #13
0
        protected static void InternalBlame(IAprUnmanaged pathOrUrl,
                                            SvnOptRevision start, SvnOptRevision end,
                                            BlameReceiver receiver, IntPtr baton,
                                            SvnClientContext ctx, AprPool pool)
        {
            SvnDelegate receiverDelegate = new SvnDelegate(receiver);

            Debug.WriteLine(String.Format("svn_client_blame({0},{1},{2},{3},{4:X},{5},{6})", pathOrUrl, start, end, receiver.Method.Name, baton.ToInt32(), ctx, pool));
            SvnError err = Svn.svn_client_blame(pathOrUrl.ToIntPtr(), start, end,
                                                (Svn.svn_client_blame_receiver_t)receiverDelegate.Wrapper,
                                                baton,
                                                ctx, pool);

            if (!err.IsNoError)
            {
                throw new SvnException(err);
            }
        }
コード例 #14
0
        public static void Log(AprArray targets,
                               SvnOptRevision start, SvnOptRevision end,
                               bool discoverChangedPaths, bool strictNodeHistory,
                               LogMessageReceiver receiver, IntPtr baton,
                               SvnClientContext ctx, AprPool pool)
        {
            SvnDelegate receiverDelegate = new SvnDelegate(receiver);

            Debug.WriteLine(String.Format("svn_client_log({0},{1},{2},{3},{4},{5},{6:X},{7},{8})", targets, start, end, discoverChangedPaths, strictNodeHistory, receiver.Method.Name, baton.ToInt32(), ctx, pool));
            SvnError err = Svn.svn_client_log(targets, start, end,
                                              (discoverChangedPaths ? 1 :0),
                                              (strictNodeHistory ? 1 :0),
                                              (Svn.svn_log_message_receiver_t)receiverDelegate.Wrapper,
                                              baton,
                                              ctx, pool);

            if (!err.IsNoError)
            {
                throw new SvnException(err);
            }
        }
コード例 #15
0
        public static void Log(AprArray targets,
							   SvnOptRevision start, SvnOptRevision end,
							   bool discoverChangedPaths, bool strictNodeHistory,
							   LogMessageReceiver receiver, IntPtr baton,
							   SvnClientContext ctx, AprPool pool)
        {
            SvnDelegate receiverDelegate = new SvnDelegate(receiver);
            Debug.WriteLine(String.Format("svn_client_log({0},{1},{2},{3},{4},{5},{6:X},{7},{8})",targets,start,end,discoverChangedPaths,strictNodeHistory,receiver.Method.Name,baton.ToInt32(),ctx,pool));
            SvnError err = Svn.svn_client_log(targets, start, end,
                                              (discoverChangedPaths ? 1 :0),
                                              (strictNodeHistory ? 1 :0),
                                              (Svn.svn_log_message_receiver_t)receiverDelegate.Wrapper,
                                              baton,
                                              ctx, pool);
            if( !err.IsNoError )
                throw new SvnException(err);
        }
コード例 #16
0
 public static SvnAuthProviderObject GetPromptProvider(
 										SslClientCertPwPrompt promptFunc,
 										IntPtr promptBaton, int retryLimit, AprPool pool)
 {
     IntPtr authObj;
        		SvnDelegate auth = new SvnDelegate(promptFunc);
     Debug.Write(String.Format("svn_client_get_ssl_client_cert_pw_prompt_provider([callback:{0}],{1:X},{2},{3})...",promptFunc.Method.Name,promptBaton.ToInt32(),retryLimit,pool));
        		Svn.svn_client_get_ssl_client_cert_pw_prompt_provider(out authObj,
                                 (Svn.svn_auth_ssl_client_cert_pw_prompt_func_t) auth.Wrapper,
                                 promptBaton, retryLimit, pool);
     Debug.WriteLine(String.Format("Done({0:X})",authObj.ToInt32()));
        		return(new SvnAuthProviderObject(authObj,auth));
 }
コード例 #17
0
 private SvnAuthProviderObject(IntPtr ptr, SvnDelegate authProvider)
 {
     mAuthProviderObject = ptr;
     mAuthProvider       = authProvider;
 }
コード例 #18
0
 private SvnAuthProviderObject(IntPtr ptr)
 {
     mAuthProviderObject = ptr;
     mAuthProvider       = null;
 }
コード例 #19
0
        protected static void InternalBlame(IAprUnmanaged pathOrUrl,
								 		  SvnOptRevision start, SvnOptRevision end, 
										  BlameReceiver receiver, IntPtr baton,
										  SvnClientContext ctx, AprPool pool)
        {
            SvnDelegate receiverDelegate = new SvnDelegate(receiver);
            Debug.WriteLine(String.Format("svn_client_blame({0},{1},{2},{3},{4:X},{5},{6})",pathOrUrl,start,end,receiver.Method.Name,baton.ToInt32(),ctx,pool));
            SvnError err = Svn.svn_client_blame(pathOrUrl.ToIntPtr(), start, end,
                                                (Svn.svn_client_blame_receiver_t)receiverDelegate.Wrapper,
                                                baton,
                                                ctx, pool);
            if( !err.IsNoError )
                throw new SvnException(err);
        }
コード例 #20
0
        public static int Status(SvnPath path,
								 SvnOptRevision revision,
								 SvnWcStatus.Func statusFunc, IntPtr statusBaton,
								 bool descend, bool getAll, bool update, bool noIgnore,
			   					 SvnClientContext ctx, AprPool pool)
        {
            int rev;
            SvnDelegate statusDelegate = new SvnDelegate(statusFunc);
            Debug.Write(String.Format("svn_client_status({0},{1},{2},{3},{4:X},{5},{6},{7},{8},{9})...",path,revision,statusFunc.Method.Name,statusBaton.ToInt32(),descend,getAll,update,noIgnore,ctx,pool));
            SvnError err = Svn.svn_client_status(out rev, path, revision,
                                                 (Svn.svn_wc_status_func_t) statusDelegate.Wrapper,
                                                 statusBaton,
                                                 (descend ? 1 : 0), (getAll ? 1 : 0),
                                                 (update ? 1 : 0), (noIgnore ? 1 : 0),
                                                 ctx, pool);
            if( !err.IsNoError )
                throw new SvnException(err);
            Debug.WriteLine(String.Format("Done({0})",rev));
            if( update )
                return(rev);
            else
                return(-1);
        }
コード例 #21
0
 private SvnAuthProviderObject(IntPtr ptr)
 {
     mAuthProviderObject = ptr;
     mAuthProvider = null;
 }
コード例 #22
0
 private SvnAuthProviderObject(IntPtr ptr, SvnDelegate authProvider)
 {
     mAuthProviderObject = ptr;
     mAuthProvider = authProvider;
 }