• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# notify_baton类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中notify_baton的典型用法代码示例。如果您正苦于以下问题:C# notify_baton类的具体用法?C# notify_baton怎么用?C# notify_baton使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



notify_baton类属于命名空间,在下文中一共展示了notify_baton类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: Unlock

		public override void Unlock (IProgressMonitor monitor, bool breakLock, params FilePath[] paths)
		{
			nb = new notify_baton ();
			var localpool = TryStartOperation (monitor);
			try {
				IntPtr array = apr.array_make (localpool, 0, IntPtr.Size);
				foreach (string path in paths) {
					string npath = NormalizePath (path, localpool);
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, npath));
				}
				lockFileList = new ArrayList ();
				requiredLockState = LibSvnClient.NotifyLockState.Unlocked;
			
				CheckError (svn.client_unlock (array, breakLock, ctx, localpool));
				if (paths.Length != lockFileList.Count)
					throw new SubversionException ("Lock operation failed.");
			} finally {
				apr.pool_destroy (localpool);
				lockFileList = null;
				TryEndOperation ();
			}
		}
开发者ID:LogosBible,项目名称:monodevelop,代码行数:23,代码来源:SvnClient.cs


示例2: Add

		public override void Add (FilePath path, bool recurse, ProgressMonitor monitor)
		{
			if (path == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();

			nb = new notify_baton ();
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				string pathorurl = NormalizePath (path, localpool);
				CheckError (svn.client_add3 (pathorurl, recurse, true, false, ctx, localpool));
			} finally {
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:15,代码来源:SvnClient.cs


示例3: Commit

		public override void Commit (FilePath[] paths, string message, IProgressMonitor monitor)
		{
			if (paths == null || message == null || monitor == null)
				throw new ArgumentNullException();

			nb = new notify_baton ();
			var localpool = TryStartOperation (monitor);
			try {
				// Put each item into an APR array.
				IntPtr array = apr.array_make (localpool, 0, IntPtr.Size);
				foreach (string path in paths) {
					string npath = NormalizePath (path, localpool);
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, npath));
				}

				IntPtr commit_info = IntPtr.Zero;
				commitmessage = message;
				
				CheckError (svn.client_commit (ref commit_info, array, false, ctx, localpool));
				unsafe {
					if (commit_info != IntPtr.Zero) {
						monitor.Log.WriteLine ();
						monitor.Log.WriteLine (GettextCatalog.GetString ("Revision: {0}", ((LibSvnClient.svn_client_commit_info_t *) commit_info.ToPointer())->revision));
					}
				}
			} finally {
				commitmessage = null;
				apr.pool_destroy (localpool);
				TryEndOperation ();
			}
		}
开发者ID:LogosBible,项目名称:monodevelop,代码行数:32,代码来源:SvnClient.cs


示例4: Delete

		public override void Delete (FilePath path, bool force, IProgressMonitor monitor)
		{
			if (path == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();

			nb = new notify_baton ();
			var localpool = TryStartOperation (monitor);
			try {
				// Put each item into an APR array.
				IntPtr array = apr.array_make (localpool, 0, IntPtr.Size);
				//foreach (string path in paths) {
					string npath = NormalizePath (path, localpool);
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, npath));
				//}
				IntPtr commit_info = IntPtr.Zero;
				CheckError (svn.client_delete (ref commit_info, array, force, ctx, localpool));
			} finally {
				commitmessage = null;
				apr.pool_destroy (localpool);
				TryEndOperation ();
			}
		}
开发者ID:LogosBible,项目名称:monodevelop,代码行数:23,代码来源:SvnClient.cs


示例5: Move

		public override void Move (FilePath srcPath, FilePath destPath, SvnRevision rev, bool force, ProgressMonitor monitor)
		{
			if (srcPath == FilePath.Null || destPath == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();
			
			LibSvnClient.Rev revision = (LibSvnClient.Rev) rev;

			nb = new notify_baton ();
			IntPtr commit_info = IntPtr.Zero;
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				string nsrcPath = NormalizePath (srcPath, localpool);
				string ndestPath = NormalizePath (destPath, localpool);
				CheckError (svn.client_move (ref commit_info, nsrcPath, ref revision,
				                             ndestPath, force, ctx, localpool));
			} finally {
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:20,代码来源:SvnClient.cs


示例6: Commit

		public override void Commit (FilePath[] paths, string message, IProgressMonitor monitor)
		{
			if (paths == null || message == null || monitor == null)
				throw new ArgumentNullException();
			
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}
			
			nb = new notify_baton ();
			updatemonitor = monitor;
			
			IntPtr localpool = newpool (pool);
			try {
				// Put each item into an APR array.
				IntPtr array = apr.array_make (localpool, 0, IntPtr.Size);
				foreach (string path in paths) {
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, path));
				}
				
				IntPtr commit_info = IntPtr.Zero;
				
				commitmessage = message;
				
				CheckError (svn.client_commit (ref commit_info, array, 0, ctx, localpool));
				unsafe {
					if (commit_info != IntPtr.Zero) {
						monitor.Log.WriteLine ();
						monitor.Log.WriteLine (GettextCatalog.GetString ("Revision: {0}", ((LibSvnClient.svn_client_commit_info_t *) commit_info.ToPointer())->revision));
					}
				}
			} finally {
				commitmessage = null;
				updatemonitor = null;
				apr.pool_destroy (localpool);
				inProgress = false;
			}
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:41,代码来源:SvnClient.cs


示例7: Delete

		public override void Delete (FilePath path, bool force, IProgressMonitor monitor)
		{
			if (path == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();
			
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}
			
			nb = new notify_baton ();
			updatemonitor = monitor;
			
			IntPtr localpool = newpool (pool);
			try {
				// Put each item into an APR array.
				IntPtr array = apr.array_make (localpool, 0, IntPtr.Size);
				//foreach (string path in paths) {
					string npath = NormalizePath (path, localpool);
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, npath));
				//}
				IntPtr commit_info = IntPtr.Zero;
				CheckError (svn.client_delete (ref commit_info, array, (force ? 1 : 0), ctx, localpool));
			} finally {
				commitmessage = null;
				updatemonitor = null;
				apr.pool_destroy (localpool);
				inProgress = false;
			}
		}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:32,代码来源:SvnClient.cs


示例8: Mkdir

		public override void Mkdir (string[] paths, string message, ProgressMonitor monitor) 
		{
			if (paths == null || monitor == null)
				throw new ArgumentNullException ();

			nb = new notify_baton ();
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				IntPtr array = NormalizePaths (localpool, paths.Select (p => (FilePath)p).ToArray ());
				
				commitmessage = message;

				IntPtr commit_info = IntPtr.Zero;
				CheckError (svn.client_mkdir2 (ref commit_info, array, ctx, localpool));
			} finally {	
				commitmessage = null;
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:20,代码来源:SvnClient.cs


示例9: Add

		public override void Add (FilePath path, bool recurse, IProgressMonitor monitor)
		{
			if (path == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();
			
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}
			nb = new notify_baton ();
			updatemonitor = monitor;
			IntPtr localpool = newpool (pool);
			try {
				string pathorurl = NormalizePath (path, localpool);
				CheckError (svn.client_add3 (pathorurl, (recurse ? 1 : 0), 1, 0, ctx, localpool));
			} finally {
				apr.pool_destroy (localpool);
				updatemonitor = null;
				inProgress = false;
			}
		}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:22,代码来源:SvnClient.cs


示例10: Checkout

		public override void Checkout (string url, FilePath path, Revision revision, bool recurse, IProgressMonitor monitor)
		{
			if (url == null || monitor == null)
				throw new ArgumentNullException ();
			
			if (revision == null)
				revision = SvnRevision.Head;
			LibSvnClient.Rev rev = (LibSvnClient.Rev) revision;
			
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}
			nb = new notify_baton ();
			updatemonitor = monitor;
			IntPtr result_rev = IntPtr.Zero;
			IntPtr localpool = newpool (pool);
			try {
				// Using Uri here because the normalization method doesn't remove the redundant port number when using https
				url = NormalizePath (new Uri(url).ToString(), localpool);
				string npath = NormalizePath (path, localpool);
				CheckError (svn.client_checkout (result_rev, url, npath, ref rev, (recurse ? 1 :0), ctx, localpool));
			} finally {
				apr.pool_destroy (localpool);
				updatemonitor = null;
				inProgress = false;
			}
		}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:29,代码来源:SvnClient.cs


示例11: Mkdir

		public override void Mkdir (string[] paths, string message, IProgressMonitor monitor) 
		{
			if (paths == null || monitor == null)
				throw new ArgumentNullException ();
		
			TryStartOperation ();

			nb = new notify_baton ();
			updatemonitor = monitor;
			
			IntPtr localpool = newpool(pool);
			try {
				// Put each item into an APR array.
				IntPtr array = apr.array_make (localpool, paths.Length, IntPtr.Size);
				foreach (string path in paths) {
					string npath = NormalizePath (path, localpool);
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, npath));
				}
				
				commitmessage = message;

				IntPtr commit_info = IntPtr.Zero;
				CheckError (svn.client_mkdir2 (ref commit_info, array, ctx, localpool));
			} finally {	
				commitmessage = null;
				updatemonitor = null;
				apr.pool_destroy (localpool);
				TryEndOperation ();
			}
		}
开发者ID:pjt33,项目名称:monodevelop,代码行数:31,代码来源:SvnClient.cs


示例12: Add

		public override void Add (FilePath path, bool recurse, IProgressMonitor monitor)
		{
			if (path == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();

			TryStartOperation ();

			nb = new notify_baton ();
			updatemonitor = monitor;
			IntPtr localpool = newpool (pool);
			try {
				string pathorurl = NormalizePath (path, localpool);
				CheckError (svn.client_add3 (pathorurl, recurse, true, false, ctx, localpool));
			} finally {
				apr.pool_destroy (localpool);
				updatemonitor = null;
				TryEndOperation ();
			}
		}
开发者ID:pjt33,项目名称:monodevelop,代码行数:19,代码来源:SvnClient.cs


示例13: Mkdir

		public override void Mkdir (string[] paths, string message, IProgressMonitor monitor) 
		{
			if (paths == null || monitor == null)
				throw new ArgumentNullException ();
		
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}

			nb = new notify_baton ();
			updatemonitor = monitor;
			
			IntPtr localpool = newpool(pool);
			try {
				// Put each item into an APR array.
				IntPtr array = apr.array_make (localpool, paths.Length, IntPtr.Size);
				foreach (string path in paths) {
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, path));
				}
				
				commitmessage = message;

				IntPtr commit_info = IntPtr.Zero;
				CheckError (svn.client_mkdir2 (ref commit_info, array, ctx, localpool));
			} finally {	
				commitmessage = null;
				updatemonitor = null;
				apr.pool_destroy (localpool);
				inProgress = false;
			}
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:34,代码来源:SvnClient.cs


示例14: Checkout

		public override void Checkout (string url, FilePath path, Revision revision, bool recurse, ProgressMonitor monitor)
		{
			if (url == null || monitor == null)
				throw new ArgumentNullException ();
			
			if (revision == null)
				revision = SvnRevision.Head;
			var rev = (LibSvnClient.Rev) revision;
			
			nb = new notify_baton ();
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				// Using Uri here because the normalization method doesn't remove the redundant port number when using https
				url = NormalizePath (new Uri(url).ToString(), localpool);
				string npath = NormalizePath (path, localpool);
				CheckError (svn.client_checkout (IntPtr.Zero, url, npath, ref rev, recurse, ctx, localpool));
			} catch (SubversionException e) {
				if (e.ErrorCode != 200015)
					throw;

				if (Directory.Exists (path.ParentDirectory))
					FileService.DeleteDirectory (path.ParentDirectory);
			} finally {
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:27,代码来源:SvnClient.cs


示例15: Move

		public override void Move (FilePath srcPath, FilePath destPath, SvnRevision rev, bool force, IProgressMonitor monitor)
		{
			if (srcPath == FilePath.Null || destPath == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();
			
			LibSvnClient.Rev revision = (LibSvnClient.Rev) rev;
			
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}
			
			nb = new notify_baton ();
			updatemonitor = monitor;
			IntPtr commit_info = IntPtr.Zero;
			IntPtr localpool = newpool (pool);
			try {
				string nsrcPath = NormalizePath (srcPath, localpool);
				string ndestPath = NormalizePath (destPath, localpool);
				CheckError (svn.client_move (ref commit_info, nsrcPath, ref revision,
				                             ndestPath, (force ? 1 : 0), ctx, localpool));
			} finally {
				apr.pool_destroy (localpool);
				updatemonitor = null;
				inProgress = false;
			}
		}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:28,代码来源:SvnClient.cs


示例16: Commit

		public override void Commit (FilePath[] paths, string message, ProgressMonitor monitor)
		{
			if (paths == null || message == null || monitor == null)
				throw new ArgumentNullException();

			nb = new notify_baton ();
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				IntPtr array = NormalizePaths (localpool, paths);
				IntPtr commit_info = IntPtr.Zero;
				commitmessage = message;
				
				CheckError (svn.client_commit (ref commit_info, array, false, ctx, localpool));
				unsafe {
					if (commit_info != IntPtr.Zero) {
						monitor.Log.WriteLine ();
						monitor.Log.WriteLine (GettextCatalog.GetString ("Revision: {0}", ((LibSvnClient.svn_client_commit_info_t *) commit_info.ToPointer())->revision));
					}
				}
			} finally {
				commitmessage = null;
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:25,代码来源:SvnClient.cs


示例17: Unlock

		public override void Unlock (IProgressMonitor monitor, bool breakLock, params FilePath[] paths)
		{
			lock (sync) {
				if (inProgress)
					throw new SubversionException ("Another Subversion operation is already in progress.");
				inProgress = true;
			}
			
			IntPtr localpool = newpool (pool);
			IntPtr array = apr.array_make (localpool, 0, IntPtr.Size);
			updatemonitor = monitor;
			nb = new notify_baton ();
			
			try {
				foreach (string path in paths) {
					string npath = NormalizePath (path, localpool);
					IntPtr item = apr.array_push (array);
					Marshal.WriteIntPtr (item, apr.pstrdup (localpool, npath));
				}
				lockFileList = new ArrayList ();
				requiredLockState = LibSvnClient.NotifyLockState.Unlocked;
			
				CheckError (svn.client_unlock (array, breakLock ? 1 : 0, ctx, localpool));
				if (paths.Length != lockFileList.Count)
					throw new SubversionException ("Lock operation failed.");
			} finally {
				apr.pool_destroy (localpool);
				lockFileList = null;
				updatemonitor = null;
				inProgress = false;
			}
		}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:32,代码来源:SvnClient.cs


示例18: Delete

		public override void Delete (FilePath path, bool force, ProgressMonitor monitor)
		{
			if (path == FilePath.Null || monitor == null)
				throw new ArgumentNullException ();

			nb = new notify_baton ();
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				IntPtr array = NormalizePaths (localpool, path);
				IntPtr commit_info = IntPtr.Zero;
				CheckError (svn.client_delete (ref commit_info, array, force, ctx, localpool));
			} finally {
				commitmessage = null;
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:17,代码来源:SvnClient.cs


示例19: Checkout

		public override void Checkout (string url, FilePath path, Revision revision, bool recurse, IProgressMonitor monitor)
		{
			if (url == null || monitor == null)
				throw new ArgumentNullException ();
			
			if (revision == null)
				revision = SvnRevision.Head;
			LibSvnClient.Rev rev = (LibSvnClient.Rev) revision;
			
			nb = new notify_baton ();
			var localpool = TryStartOperation (monitor);
			try {
				// Using Uri here because the normalization method doesn't remove the redundant port number when using https
				url = NormalizePath (new Uri(url).ToString(), localpool);
				string npath = NormalizePath (path, localpool);
				CheckError (svn.client_checkout (IntPtr.Zero, url, npath, ref rev, recurse, ctx, localpool));
			} finally {
				apr.pool_destroy (localpool);
				TryEndOperation ();
			}
		}
开发者ID:jrhtcg,项目名称:monodevelop,代码行数:21,代码来源:SvnClient.cs


示例20: Unlock

		public override void Unlock (ProgressMonitor monitor, bool breakLock, params FilePath[] paths)
		{
			nb = new notify_baton ();
			IntPtr localpool = IntPtr.Zero;
			try {
				localpool = TryStartOperation (monitor);
				IntPtr array = NormalizePaths (localpool, paths);
				lockFileList = new ArrayList ();
				requiredLockState = LibSvnClient.NotifyLockState.Unlocked;
			
				CheckError (svn.client_unlock (array, breakLock, ctx, localpool));
				if (paths.Length != lockFileList.Count)
					throw new SubversionException ("Unlock operation failed.");
			} finally {
				lockFileList = null;
				TryEndOperation (localpool);
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:18,代码来源:SvnClient.cs



注:本文中的notify_baton类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# nsIRequest类代码示例发布时间:2022-05-24
下一篇:
C# northwindDataSet类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap