When to use the "as" keyword and when to use () casting? [duplicate]
Possible Duplicate:
Direct casting vs 'as' operator?
as doesn't throw an exception, but开发者_运维技巧 wouldn't it result in a NullPointerException later? doesn't it make it harder to debug?
after using the as, you should always check for null.
精彩评论