Exemplo n.º 1
0
 private void SetAllNull()
 {
     HasEntries    = false;
     Entries       = new SLEntries();
     Sets          = new List <SLTupleSet>();
     QueryCache    = new List <SLQuery>();
     ServerFormats = new List <SLServerFormat>();
 }
        internal SLEntries Clone()
        {
            var es = new SLEntries();

            es.Items = new List <SLEntriesItemsTypeIndexPair>();
            foreach (var pair in Items)
            {
                es.Items.Add(new SLEntriesItemsTypeIndexPair(pair.Type, pair.Index));
            }

            es.MissingItems = new List <SLMissingItem>();
            foreach (var mi in MissingItems)
            {
                es.MissingItems.Add(mi.Clone());
            }

            es.NumberItems = new List <SLNumberItem>();
            foreach (var ni in NumberItems)
            {
                es.NumberItems.Add(ni.Clone());
            }

            es.ErrorItems = new List <SLErrorItem>();
            foreach (var ei in ErrorItems)
            {
                es.ErrorItems.Add(ei.Clone());
            }

            es.StringItems = new List <SLStringItem>();
            foreach (var si in StringItems)
            {
                es.StringItems.Add(si.Clone());
            }

            return(es);
        }