惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

GbyAI
GbyAI
C
Cybersecurity and Infrastructure Security Agency CISA
IT之家
IT之家
罗磊的独立博客
阮一峰的网络日志
阮一峰的网络日志
MongoDB | Blog
MongoDB | Blog
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
L
LINUX DO - 最新话题
C
Cyber Attacks, Cyber Crime and Cyber Security
Cyberwarzone
Cyberwarzone
S
SegmentFault 最新的问题
S
Schneier on Security
A
About on SuperTechFans
L
Lohrmann on Cybersecurity
博客园_首页
D
Darknet – Hacking Tools, Hacker News & Cyber Security
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
S
Securelist
博客园 - 司徒正美
H
Hacker News: Front Page
Jina AI
Jina AI
K
Kaspersky official blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
量子位
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
J
Java Code Geeks
B
Blog
Google DeepMind News
Google DeepMind News
博客园 - Franky
The Cloudflare Blog
M
MIT News - Artificial intelligence
Blog — PlanetScale
Blog — PlanetScale
H
Help Net Security
Spread Privacy
Spread Privacy
N
News and Events Feed by Topic
A
Arctic Wolf
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
宝玉的分享
宝玉的分享
T
The Blog of Author Tim Ferriss
O
OpenAI News
N
Netflix TechBlog - Medium
G
GRAHAM CLULEY
F
Fortinet All Blogs
V
V2EX
N
News | PayPal Newsroom
Y
Y Combinator Blog
雷峰网
雷峰网
博客园 - 叶小钗
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Recent Commits to openclaw:main
Recent Commits to openclaw:main

博客园 - MSFT:waywa 韦恩卑鄙

[UWP]一种利用Behavior 将StateTrigger集中管理的方案 【干货】个人工作文档节选:XAML MVVM 框架易用性细节优化Tips MVVM Sidekick Win8 RT 轻量级MVVM框架开源 对资源加读写锁的容器 对不能用using的成对操作,快速扩展IDisposable的方法 intel I7平台Win7 x64 下wpf、silverlight 与aero特效动画缓慢故障排除一则 1080*1920 下看网站很爽 游戏大厅 从基础开始(8)--绕回来细说聊天室(下)垃圾列表 游戏大厅 从基础开始(7)--绕回来细说聊天室(中间偏下)之女仆编年史2 游戏大厅 从基础开始(6)--绕回来细说聊天室(中)之女仆编年史1 - MSFT:waywa 韦恩卑鄙 游戏大厅 从基础开始(5)--绕回来细说聊天室(上) 简单的树遍历枚举器v0.2-挑战一个程序员到底能多懒- 添加广度优先遍历 一时技痒 不用模拟第一印象的构造 通过三个观察得来的规律解决N^2个往返接力问题 游戏大厅 从基础开始(4)-通过L2X用配置文件反射组装程序(VB only) 关于silverlight depencyobject简单的clone silver light 2 客户端的伪DataTable for EF X360吉他英雄4鼓套装 &1 TB硬盘入手 游戏大厅 从基础开始(3.5)——最吸引眼球的部分 客户端与服务器的连接 的实现 游戏大厅 从基础开始(3)——最吸引眼球的部分 客户端与服务器的连接
今天被Prism里面的一段代码雷到了
MSFT:waywa 韦恩卑鄙 · 2010-02-20 · via 博客园 - MSFT:waywa 韦恩卑鄙
        public virtual bool CanExecute(object parameter)
        {
            bool hasEnabledCommandsThatShouldBeExecuted = false;

            ICommand[] commandList;
            lock (this.registeredCommands)
            {
                commandList = this.registeredCommands.ToArray();
            }
            foreach (ICommand command in commandList)
            {
                if (this.ShouldExecute(command))
                {
                    if (!command.CanExecute(parameter))
                    {
                        return false;
                    }

                    hasEnabledCommandsThatShouldBeExecuted = true;
                }
            }

            return hasEnabledCommandsThatShouldBeExecuted;
        }