コード例 #1
0
        internal FuzzyInt(StoragePremitive x, LinkedList <object> path)
        {
            Compound comp = (Compound)x;

            UpperBound = comp[16] is DsDouble ? (int)(comp[16] as DsDouble).Value : (int)(comp[16] as SignedInteger).Value;
            LowerBound = comp[17] is DsDouble ? (int)(comp[17] as DsDouble).Value : (int)(comp[17] as SignedInteger).Value;
        }
コード例 #2
0
        public MapLocInfo(StoragePremitive info, LinkedList <object> serializationPath)
        {
            var comp = (Compound)info;

            MapAreaId = (int)(SignedInteger)comp[16];
            MapSectId = (int)(SignedInteger)comp[17];
            MapLocId  = (int)(SignedInteger)comp[18];
        }
コード例 #3
0
        /*public Histogram(ILogbook log, IEnumerable<KeyValuePair<long, T>> data)
         * {
         *  foreach(var ent in data) backend.Add(ent.Key, ent.Value);
         * }*/

        public Histogram(StoragePremitive p, LinkedList <object> path)
        {
            path.AddFirst(this);
            foreach (var kv in ((Premitives.Dictionary <SignedInteger, StoragePremitive>)p).Convert((k, v) => new KeyValuePair <long, T>(k.Value, revConverter(v, path))))
            {
                backend.Add(kv.Key, kv.Value);
            }
            path.RemoveFirst();
            _holder = (ILogbook)path.First(x => x is ILogbook);
        }
コード例 #4
0
 public static void Serialize(this StoragePremitive p, DSWriter w)
 {
     if (p == null)
     {
         w.Write(EnumerablesEx.AsEnumerable(TypeIdentifier.Null));
     }
     else
     {
         p.SerializeNonNull(w);
     }
 }
コード例 #5
0
 internal BattleProcess(StoragePremitive x, LinkedList <object> path) : base(x, path)
 {
 }
コード例 #6
0
 internal ShipHpStatus(StoragePremitive x, LinkedList <object> path) : base(x, path)
 {
     _parent = path.FirstOrDefault(p => p is BattleProcess) as BattleProcess;
 }
コード例 #7
0
 internal SupportInfo(StoragePremitive x, LinkedList <object> path) : base(x, path)
 {
 }
コード例 #8
0
 internal BombardInfo(StoragePremitive x, LinkedList <object> path) : base(x, path)
 {
     _parent = path.FirstOrDefault(p => p is IShipInfoHolder) as IShipInfoHolder;
 }
コード例 #9
0
 internal ParameterInfo(StoragePremitive x, LinkedList <object> path) : base(x, path)
 {
 }