Beispiel #1
0
 public void AddInnerInfo(InnerInfo info)
 {
     if (info != null)
     {
         innerInfos.Add(info);
     }
 }
Beispiel #2
0
 public void Setup()
 {
     date = new DateTime(1641, 6, 11);
     player = "ALG";
     inner = new InnerInfo()
     {
         Id = 1,
         Name = "Stocšžolm",
         DiscoveredBy = new[] { "REB", "SWE" },
         CitySize = 12.000,
         GenericInfantry = new[] { "infantry_brigade", "infantry_brigade", "infantry_brigade" }
     };
 }
Beispiel #3
0
 public FileSave()
 {
     date   = new DateTime(1641, 6, 11);
     player = "ALG";
     inner  = new InnerInfo()
     {
         Id              = 1,
         Name            = "Stocšžolm",
         DiscoveredBy    = new[] { "REB", "SWE" },
         CitySize        = 12.000,
         GenericInfantry = new[] { "infantry_brigade", "infantry_brigade", "infantry_brigade" }
     };
 }
        public void SaveNoChange()
        {
            FileStream output = new FileStream(outputPath, FileMode.Create, FileAccess.ReadWrite);
            using (ParadoxSaver saver = new ParadoxSaver(output))
            {
                var date = new DateTime(1641, 6, 11);
                var player = "ALG";
                var inner = new InnerInfo()
                {
                    Id = 1,
                    Name = "Stocšžolm",
                    DiscoveredBy = new[] {"REB", "SWE"},
                    CitySize = 12.000,
                    GenericInfantry = new[] {"infantry_brigade", "infantry_brigade", "infantry_brigade"}
                };

                saver.WriteLine("date", date);
                saver.WriteLine("player", player, ValueWrite.Quoted);
                saver.Write(inner.Id.ToString(), inner);
            }
            FileAssert.AreEqual(filePath, outputPath);
        }
Beispiel #5
0
 protected override object GetValue(object obj)
 {
     return(InnerInfo.GetValue(obj));
 }
Beispiel #6
0
 protected override void SetValue(
     object obj,
     object value)
 {
     InnerInfo.SetValue(obj, value);
 }
Beispiel #7
0
 public AuditInfo()
 {
     Request = new InnerInfo();
     Response = new InnerInfo();
 }