public static ProfileCardData Create(object item1, object item2) { LibraryDataProviderListItem libraryData = null; XmlDataProviderObject serviceData = null; if (item1 is LibraryDataProviderListItem) { libraryData = (LibraryDataProviderListItem)item1; } else if (item1 is XmlDataProviderObject) { serviceData = (XmlDataProviderObject)item1; } switch (item2) { case LibraryDataProviderListItem _: libraryData = (LibraryDataProviderListItem)item2; break; case XmlDataProviderObject _: serviceData = (XmlDataProviderObject)item2; break; } return(new ProfileCardData(libraryData, serviceData)); }
internal ProfileCardData( LibraryDataProviderListItem libraryData, XmlDataProviderObject serviceData) { this._libraryData = libraryData; this._serviceData = serviceData; this._isFriend = false; this._badgeCount = -1; }