public void Insert()
        {
            if (_pluginData.Any?.Length == 1)
            {
                var ddi = DVDProfilerSerializer <DDI.DigitalDownloadInfo> .FromString(_pluginData.Any[0].OuterXml);

                InsertPluginData(ddi);
            }
        }
Esempio n. 2
0
        public void Insert()
        {
            if (_pluginData.Any?.Length == 1)
            {
                var ef = DVDProfilerSerializer <EF.EnhancedFeatures> .FromString(_pluginData.Any[0].OuterXml);

                Insert(ef);
            }
        }
Esempio n. 3
0
        private static DVD GetDvd(ListView listView)
        {
            Int32 selectedIndex = listView.SelectedIndices[0];

            String xml = (String)(listView.Items[selectedIndex].Tag);

            DVD dvd = DVDProfilerSerializer <DVD> .FromString(xml, Collection.DefaultEncoding);

            return(dvd);
        }
Esempio n. 4
0
        public void Insert()
        {
            if (_pluginData.Any?.Length == 1)
            {
                var en = DVDProfilerSerializer <EN.EnhancedNotes> .FromString(_pluginData.Any[0].OuterXml);

                InsertMetaData(en);

                InsertPluginData(en);
            }
        }
            private static String GetCleanedProfile(String rawProfileXml)
            {
                DVD cleanedProfile = DVDProfilerSerializer <DVD> .FromString(rawProfileXml, Collection.DefaultEncoding);

                cleanedProfile.LastEditedSpecified = false;
                cleanedProfile.ProfileTimestamp    = new DateTime(0);

                String cleanedProfileXml = DVDProfilerSerializer <DVD> .ToString(cleanedProfile, Collection.DefaultEncoding);

                return(cleanedProfileXml);
            }
Esempio n. 6
0
        public void Insert()
        {
            if (_pluginData.Any?.Length == 1)
            {
                var epi = DVDProfilerSerializer <EPI.EnhancedPurchaseInfo> .FromString(_pluginData.Any[0].OuterXml);

                InsertMetaData(epi);

                InsertPluginData(epi);
            }
        }
Esempio n. 7
0
        public CompareForm(IEnumerable <ProfileTuple> profiles)
        {
            InitializeComponent();

            String profileXml = profiles.First().ProfileXml;

            DVD profile = DVDProfilerSerializer <DVD> .FromString(profileXml, Collection.DefaultEncoding);

            Text += ": " + profile.Title;

            AddRows(LeftListView, profiles);
            AddRows(RightListView, profiles);
        }
Esempio n. 8
0
        private static T TryGetInformationFromData <T>(string data) where T : class, new()
        {
            try
            {
                var information = DVDProfilerSerializer <T> .FromString(data, CastInformation.DefaultEncoding);

                return(information);
            }
            catch
            {
                return(null);
            }
        }
Esempio n. 9
0
        private Dictionary <DVD, IEnumerable <ProfileTuple> > Convert()
        {
            Dictionary <DVD, IEnumerable <ProfileTuple> > profiles = new Dictionary <DVD, IEnumerable <ProfileTuple> >(_Profiles.Count);

            foreach (KeyValuePair <DVD, List <ExtendedProfileTuple> > kvp in _Profiles)
            {
                if (kvp.Value.Count > 1)
                {
                    String newestXml = kvp.Value.Last().ProfileXml;

                    DVD newest = DVDProfilerSerializer <DVD> .FromString(newestXml, Collection.DefaultEncoding);

                    IEnumerable <ProfileTuple> profileList = kvp.Value.Select(p => p.Simplify()).ToList();

                    profiles.Add(newest, profileList);
                }
            }

            return(profiles);
        }