case PLAYER:
return new PlayerPopupView((PlayerContentItem) contentItem);
case BACKGROUND:
return new ContentItemPreviewWithHeader(contentItem);
case ASSET:
AssetContentItem asset = (AssetContentItem) contentItem;
switch (asset.getAssetType()) {
case VIDEO:
case INTERACTIVE:
return new BaseAssetPopupView(asset);
case DOCUMENT:
return new DocumentPopupView(asset);
case IMAGE:
return new ImagePopupView(asset);
default:
throw new IllegalArgumentException("Asset type " + asset.getAssetType()
+ " does not have a popup view defined.");
}
default:
throw new IllegalArgumentException("Content item type " + contentItem.getContentItemType()
+ " does not have a popup view defined.");