BindToItemGeneric<TItem extends Item> method
Implementation
Future<TItem> BindToItemGeneric<TItem extends Item>(
ItemId? itemId, PropertySet propertySet) async {
Item? result = await this.BindToItem(itemId, propertySet);
if (result is TItem) {
return result;
} else {
throw new ServiceLocalException("""string.Format(
Strings.ItemTypeNotCompatible,
result.GetType().Name,
typeof(TItem).Name)""");
}
}