static void Main(String[] args) { var Option = new COptionStream <SKey>("Option.ini", false); Option.Data.PeerNum = 'q'; Option.Save(); Console.WriteLine(Option.Data); }
public _SClient(TPeerCnt PeerNum_, String DataPath_, CNamePort AuthNamePort_, TUID SubUID_, CStream Stream_) // For Login { CaProto = EProto.CaLogin; MasterNamePort = new COptionStream <CNamePort>(DataPath_ + "Master_" + PeerNum_.ToString() + ".dat", true); LastLoginInfo = new COptionStream <SLoginInfo>(DataPath_ + "LastLoginInfo_" + PeerNum_.ToString() + ".dat", true); AuthNamePort = AuthNamePort_; UID = LastLoginInfo.Data.UID; ID = LastLoginInfo.Data.ID; SubUID = SubUID_; Stream = Stream_; Directory.CreateDirectory(DataPath_); }
public _SServer(TPeerCnt PeerCounter_, CNamePort MasterNamePort_, string DataFile_) { PeerCounter = PeerCounter_; ParentNamePort = new COptionStream <CNamePort>(DataFile_, true); ConnectNamePorts.Add(MasterNamePort_); if (ParentNamePort.Data && !ParentNamePort.Data.Equals(MasterNamePort_)) { ConnectNamePorts.Add(ParentNamePort.Data); } }
public CClientCore(string FileName_, string DataPath_) { _Data = new COptionStream <SPatchData>(FileName_, true); _DataPathFull = Environment.CurrentDirectory.Combine(DataPath_); Directory.CreateDirectory(Path.GetFullPath(_DataPathFull)); }
public _SServer(string FileName_) { NamePort = new COptionStream <CNamePort>(FileName_, true); }