View DesktopAppBar.cs
using System; | |
using System.ComponentModel; | |
using System.Diagnostics.CodeAnalysis; | |
using System.Runtime.InteropServices; | |
using System.Threading.Tasks; | |
using System.Windows; | |
using System.Windows.Interop; | |
// ReSharper disable IdentifierTypo | |
// ReSharper disable InconsistentNaming |
View VisualScalingExtensions
using System; | |
using System.Windows; | |
using System.Windows.Media; | |
namespace Walterlv | |
{ | |
public static class VisualScalingExtensions | |
{ | |
/// <summary> | |
/// 获取一个 <paramref name="visual"/> 在显示设备上的尺寸相对于自身尺寸的缩放比。 |
View ExceptionDescriptor.cs
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; | |
using System.Linq; | |
namespace Walterlv | |
{ | |
/// <summary> | |
/// 包含一个 <see cref="Exception"/> 对象的关键特征,可使用此对象的实例判断两个不同的异常实例是否极有可能表示同一个异常。 | |
/// </summary> |
View SelfInstaller.cs
using System; | |
using System.Collections.Generic; | |
using System.Diagnostics; | |
using System.IO; | |
using System.Linq; | |
using System.Reflection; | |
using System.Security.Principal; | |
namespace Walterlv.Installing | |
{ |
View ContinuousPartOperation.cs
using System; | |
using System.Diagnostics; | |
using System.Runtime.CompilerServices; | |
using System.Threading.Tasks; | |
namespace Walterlv | |
{ | |
/// <summary> | |
/// 为一个持续操作中的一部分提供可异步等待的操作。 | |
/// </summary> |
View FileWatcher.cs
using System; | |
using System.IO; | |
namespace Walterlv.IO | |
{ | |
public sealed class FileWatcher | |
{ | |
/// <summary>监视的文件。</summary> | |
private readonly FileInfo _file; |
View AsyncBox.cs
using System; | |
using System.Collections; | |
using System.ComponentModel; | |
using System.Threading.Tasks; | |
using System.Windows; | |
using System.Windows.Controls; | |
using System.Windows.Markup; | |
using System.Windows.Media; | |
using System.Windows.Threading; | |
using Walterlv.Demo; |
View CachePool.cs
using System; | |
using System.Collections.Generic; | |
using Walterlv.Annotations; | |
namespace Walterlv | |
{ | |
/// <summary> | |
/// 如果获取 <typeparamref name="TSource"/> 对应信息的过程比较耗时(例如反射), | |
/// 则可使用 <see cref="CachePool{TSource,TCache}"/> 对此过程进行缓存。 | |
/// </summary> |
View AwaiterInterfaces.cs
using System.Runtime.CompilerServices; | |
namespace Walterlv.Threading | |
{ | |
/// <summary> | |
/// 表示一个可等待对象,如果一个方法返回此类型的实例,则此方法可以使用 `await` 异步等待。 | |
/// </summary> | |
/// <typeparam name="TAwaiter">用于给 await 确定返回时机的 IAwaiter 的实例。</typeparam> | |
public interface IAwaitable<out TAwaiter> where TAwaiter : IAwaiter | |
{ |
View CommandArgumentAttribute.cs
using System; | |
namespace Mdmeta.Core | |
{ | |
/// <summary> | |
/// Specify a property to receive argument of command from the user. | |
/// </summary> | |
[AttributeUsage(AttributeTargets.Property)] | |
public sealed class CommandArgumentAttribute : Attribute | |
{ |
NewerOlder