Mercurial > projects > dwt-mac
comparison dwt/dnd/HTMLTransfer.d @ 9:e76aa0b07480
Some more instanceof
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Wed, 27 Aug 2008 14:36:41 +0200 |
parents | e831403a80a9 |
children | d8635bb48c7c |
comparison
equal
deleted
inserted
replaced
8:a9ab4c738ed8 | 9:e76aa0b07480 |
---|---|
92 protected String[] getTypeNames() { | 92 protected String[] getTypeNames() { |
93 return new String[] {HTML}; | 93 return new String[] {HTML}; |
94 } | 94 } |
95 | 95 |
96 bool checkHTML(Object object) { | 96 bool checkHTML(Object object) { |
97 return (object !is null && object instanceof String && (cast(String)object).length() > 0); | 97 return (object !is null && null !is cast(String)object && (cast(String)object).length() > 0); |
98 } | 98 } |
99 | 99 |
100 protected bool validate(Object object) { | 100 protected bool validate(Object object) { |
101 return checkHTML(object); | 101 return checkHTML(object); |
102 } | 102 } |