Implemented interface member:
property
Type
System.Runtime.InteropServices.WindowsRuntime.IPropertyValue.Type
39 references to Type
mscorlib (39)
system\runtime\interopservices\windowsruntime\clripropertyvalueimpl.cs (39)
134
if (this.
Type
!= PropertyType.Char16)
135
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Char16"), __HResults.TYPE_E_TYPEMISMATCH);
143
if (this.
Type
!= PropertyType.Boolean)
144
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Boolean"), __HResults.TYPE_E_TYPEMISMATCH);
158
if (this.
Type
!= PropertyType.Inspectable)
159
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Inspectable"), __HResults.TYPE_E_TYPEMISMATCH);
175
if (this.
Type
!= PropertyType.DateTime)
176
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "DateTime"), __HResults.TYPE_E_TYPEMISMATCH);
184
if (this.
Type
!= PropertyType.TimeSpan)
185
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "TimeSpan"), __HResults.TYPE_E_TYPEMISMATCH);
194
if (this.
Type
!= PropertyType.Point)
195
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Point"), __HResults.TYPE_E_TYPEMISMATCH);
205
if (this.
Type
!= PropertyType.Size)
206
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Size"), __HResults.TYPE_E_TYPEMISMATCH);
216
if (this.
Type
!= PropertyType.Rect)
217
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Rect"), __HResults.TYPE_E_TYPEMISMATCH);
280
if (this.
Type
!= PropertyType.Char16Array)
281
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Char16[]"), __HResults.TYPE_E_TYPEMISMATCH);
289
if (this.
Type
!= PropertyType.BooleanArray)
290
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Boolean[]"), __HResults.TYPE_E_TYPEMISMATCH);
304
if (this.
Type
!= PropertyType.InspectableArray)
305
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Inspectable[]"), __HResults.TYPE_E_TYPEMISMATCH);
319
if (this.
Type
!= PropertyType.DateTimeArray)
320
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "DateTimeOffset[]"), __HResults.TYPE_E_TYPEMISMATCH);
328
if (this.
Type
!= PropertyType.TimeSpanArray)
329
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "TimeSpan[]"), __HResults.TYPE_E_TYPEMISMATCH);
338
if (this.
Type
!= PropertyType.PointArray)
339
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Point[]"), __HResults.TYPE_E_TYPEMISMATCH);
349
if (this.
Type
!= PropertyType.SizeArray)
350
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Size[]"), __HResults.TYPE_E_TYPEMISMATCH);
361
if (this.
Type
!= PropertyType.RectArray)
362
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, "Rect[]"), __HResults.TYPE_E_TYPEMISMATCH);
370
if (
Type
== unboxType) {
377
throw new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueElement", this.
Type
, typeof(T).MakeArrayType().Name), __HResults.TYPE_E_TYPEMISMATCH);
381
BCLDebug.Assert((int)
Type
> 1024, "Unexpected array PropertyType value");
382
PropertyType scalarType =
Type
- 1024;
391
Exception e = new InvalidCastException(Environment.GetResourceString("InvalidCast_WinRTIPropertyValueArrayCoersion", this.
Type
, typeof(T).MakeArrayType().Name, i, elementCastException.Message), elementCastException);
403
if (
Type
== unboxType) {
407
return CoerceScalarValue<T>(
Type
, _data);