(Type type)
| 197 | } |
| 198 | |
| 199 | public ObjectCheck GetChecker(Type type) |
| 200 | { |
| 201 | if (type.IsByRef) type = type.GetElementType(); |
| 202 | |
| 203 | Type underlyingType = Nullable.GetUnderlyingType(type); |
| 204 | if (underlyingType != null) |
| 205 | { |
| 206 | return genNullableChecker(GetChecker(underlyingType)); |
| 207 | } |
| 208 | ObjectCheck oc; |
| 209 | if (!checkersMap.TryGetValue(type, out oc)) |
| 210 | { |
| 211 | oc = genChecker(type); |
| 212 | checkersMap.Add(type, oc); |
| 213 | } |
| 214 | return oc; |
| 215 | } |
| 216 | } |
| 217 | |
| 218 | public class ObjectCasters |
no test coverage detected