/// <summary> /// Two DnsResourceDataNetworkServiceAccessPoint are iff their area address, system identifier and selector fields are equal. /// </summary> public bool Equals(DnsResourceDataNetworkServiceAccessPoint other) { return(other != null && AreaAddress.Equals(other.AreaAddress) && SystemIdentifier.Equals(other.SystemIdentifier) && Selector.Equals(other.Selector)); }
public AgentNotification(SystemNodeIdentifier Host, SystemIdentifier System, AgentIdentifier Agent, ServiceAgentState State, IAppMessage Message) { this.Host = Host; this.System = System; this.Agent = Agent; this.State = State; this.Message = Message; }
public FsdManager(IEventBroker broker, IAppConfig config) : base(broker) { mConfig = config; mSystemUID = SystemIdentifier.GetSystemDriveVolumeId(); mPositionUpdateTimer = new System.Timers.Timer(); mPositionUpdateTimer.Elapsed += PositionUpdateTimer_Elapsed; if (!Directory.Exists(Path.Combine(mConfig.AppPath, "NetworkLogs"))) { Directory.CreateDirectory(Path.Combine(mConfig.AppPath, "NetworkLogs")); } var directory = new DirectoryInfo(Path.Combine(mConfig.AppPath, "NetworkLogs")); var query = directory.GetFiles("*", SearchOption.AllDirectories); foreach (var file in query.OrderByDescending(file => file.CreationTime).Skip(10)) { file.Delete(); } ClientProperties = new ClientProperties("xPilot", mVersion, Assembly.GetEntryAssembly().Location.CheckSum(), ""); mRawDataStream = new StreamWriter(Path.Combine(mConfig.AppPath, $"NetworkLogs/NetworkLog-{DateTime.UtcNow:yyyyMMddHHmmss}.log"), false); FSD = new FSDSession(ClientProperties); FSD.IgnoreUnknownPackets = true; FSD.NetworkError += FSD_NetworkError; FSD.ProtocolErrorReceived += FSD_ProtocolErrorReceived; FSD.RawDataReceived += FSD_RawDataReceived; FSD.RawDataSent += FSD_RawDataSent; FSD.NetworkConnected += FSD_NetworkConnected; FSD.NetworkDisconnected += FSD_NetworkDisconnected; FSD.ServerIdentificationReceived += FSD_ServerIdentificationReceived; FSD.KillRequestReceived += FSD_KillRequestReceived; FSD.AcarsResponseReceived += FSD_AcarsResponseReceived; FSD.RadioMessageReceived += FSD_RadioMessageReceived; FSD.TextMessageReceived += FSD_TextMessageReceived; FSD.BroadcastMessageReceived += FSD_BroadcastMessageReceived; FSD.PilotPositionReceived += FSD_PilotPositionReceived; FSD.ATCPositionReceived += FSD_ATCPositionReceived; FSD.ClientQueryResponseReceived += FSD_ClientQueryResponseReceived; FSD.ClientQueryReceived += FSD_ClientQueryReceived; FSD.PlaneInfoRequestReceived += FSD_PlaneInfoRequestReceived; FSD.PlaneInfoResponseReceived += FSD_PlaneInfoResponseReceived; FSD.LegacyPlaneInfoResponseReceived += FSD_LegacyPlaneInfoResponseReceived; FSD.DeletePilotReceived += FSD_DeletePilotReceived; FSD.DeleteATCReceived += FSD_DeleteATCReceived; FSD.FlightPlanReceived += FSD_FlightPlanReceived; FSD.PingReceived += FSD_PingReceived; }
private void SaveChanges() { BinaryWriter bw = new BinaryWriter(File.Open(LASFileName, FileMode.Open, FileAccess.ReadWrite)); Stream bwBaseStream = bw.BaseStream; bw.Write(Encoding.ASCII.GetBytes(FileSignature)); bw.Write(FileSourceID); bw.Write(GlobalEncoding); bw.Write(GUIDArr); bw.Write(VersionMajor); bw.Write(VersionMinor); bw.Write(Encoding.ASCII.GetBytes(SystemIdentifier.PadRight(32, '\0'))); bw.Write(Encoding.ASCII.GetBytes(GeneratingSoftware.PadRight(32, '\0'))); bw.Write(FileCreationDayOfYear); bw.Write(FileCreationYear); bw.Write(HeaderSize); bw.Write(OffsetPointData); bw.Write(NumberOfVariableLengthRecords); bw.Write(PointDataRecordFormat); bw.Write(PointDataRecordLength); bw.Write(LegacyNumberOfPointRecords); for (int i = 0; i < 5; i++) bw.Write(LegacyNumberOfPointbyReturn[i]); bw.Write(XScaleFactor); bw.Write(YScaleFactor); bw.Write(ZScaleFactor); bw.Write(XOffset); bw.Write(YOffset); bw.Write(ZOffset); bw.Write(MaxX); bw.Write(MinX); bw.Write(MaxY); bw.Write(MinY); bw.Write(MaxZ); bw.Write(MinZ); if (VersionMinor > 2) bw.Write(StartOfWaveFormDataPacketRecord); bw.Close(); }
private static void Init() { Thread currentThread = Thread.CurrentThread; currentThread.Priority = ThreadPriority.Highest; currentThread.CurrentCulture = CultureInfo.InvariantCulture; CultureInfo.DefaultThreadCurrentCulture = CultureInfo.InvariantCulture; Aluna.CRenderer_GL.SetMinimumVersion(3, 2); Aluna.CRenderer_GL.SetMaximumVersion(3, 2); InitSettingsDirectory(); InitFileSystem(); SystemIdentifier.Start(); Serialization.Initialize(); Engine.InitPhysics(); m_engine = new Engine(); Engine.InitializeFlags flags = Engine.InitializeFlags.DisableResize; m_engine.Initialize("Aluna Tools Demo", 1280, 720, flags, -1); Aluna.AlunaNETBridge.CfcAlunaBridgeInitialize(m_engine.window._window); m_textRenderer = (TextRenderer_Standalone)m_engine.textDraw; m_textRenderer.AddFont("Fonts/FreeSans.ttf"); m_scene = new Scene(true); m_renderer = new SceneRenderer(m_engine, m_scene, "fullbright", "none", false); m_camera = new CameraFPS(m_engine, false); m_camera.SetPosition(new Microsoft.Xna.Framework.Vector3(2, 0, 2)); m_camera.LookAtDirection(new Microsoft.Xna.Framework.Vector3(-1, 0, 0)); m_camera.InputMoveCameraEnabled = m_camera.InputRotateCameraEnabled = false; m_door = new Door(m_engine, m_scene); m_instructGUI = new InstructionsGUI(m_textRenderer); }
public SolutionBuildResult(SystemIdentifier OwningSystem, FilePath SolutionPath, Option <BuildSummary> Summary) { this.OwningSystem = OwningSystem; this.SolutionPath = SolutionPath; this.Summary = Summary; }