Merge 13.5.3 DR_16824
Former-commit-id:7baa5ee0d5
[formerlyb8fd0f16ed
] [formerly7baa5ee0d5
[formerlyb8fd0f16ed
] [formerlydafe7e6a42
[formerly 1b9ed749da0d1893f44e68400644f37c763e324a]]] Former-commit-id:dafe7e6a42
Former-commit-id:981373f82b
[formerly8c16576a82
] Former-commit-id:bcf5bf170d
This commit is contained in:
parent
0c6ba63abc
commit
4e38785329
20 changed files with 0 additions and 1127 deletions
|
@ -1,20 +0,0 @@
|
|||
|
||||
Microsoft Visual Studio Solution File, Format Version 11.00
|
||||
# Visual C# Express 2010
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VizLauncher", "VizLauncher\VizLauncher.csproj", "{45B15612-0725-479C-8E1B-9B63F2FB45A3}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|x86 = Debug|x86
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{45B15612-0725-479C-8E1B-9B63F2FB45A3}.Debug|x86.ActiveCfg = Debug|x86
|
||||
{45B15612-0725-479C-8E1B-9B63F2FB45A3}.Debug|x86.Build.0 = Debug|x86
|
||||
{45B15612-0725-479C-8E1B-9B63F2FB45A3}.Release|x86.ActiveCfg = Release|x86
|
||||
{45B15612-0725-479C-8E1B-9B63F2FB45A3}.Release|x86.Build.0 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
Binary file not shown.
79
msi/VizLauncher/VizLauncher/Form1.Designer.cs
generated
79
msi/VizLauncher/VizLauncher/Form1.Designer.cs
generated
|
@ -1,79 +0,0 @@
|
|||
namespace VizLauncher
|
||||
{
|
||||
partial class Form1
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows Form Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.lblFailureDetail = new System.Windows.Forms.Label();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128)))));
|
||||
this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 18F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label1.Location = new System.Drawing.Point(12, 0);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(337, 50);
|
||||
this.label1.TabIndex = 0;
|
||||
this.label1.Text = "Failed to Start AWIPS II Viz!";
|
||||
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
|
||||
//
|
||||
// lblFailureDetail
|
||||
//
|
||||
this.lblFailureDetail.BackColor = System.Drawing.Color.White;
|
||||
this.lblFailureDetail.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lblFailureDetail.Location = new System.Drawing.Point(14, 59);
|
||||
this.lblFailureDetail.Name = "lblFailureDetail";
|
||||
this.lblFailureDetail.Size = new System.Drawing.Size(335, 119);
|
||||
this.lblFailureDetail.TabIndex = 1;
|
||||
//
|
||||
// Form1
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(361, 187);
|
||||
this.Controls.Add(this.lblFailureDetail);
|
||||
this.Controls.Add(this.label1);
|
||||
this.MaximizeBox = false;
|
||||
this.MinimizeBox = false;
|
||||
this.Name = "Form1";
|
||||
this.ShowInTaskbar = false;
|
||||
this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Viz Launcher";
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Label lblFailureDetail;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,20 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace VizLauncher
|
||||
{
|
||||
public partial class Form1 : Form
|
||||
{
|
||||
public Form1(String errorText)
|
||||
{
|
||||
InitializeComponent();
|
||||
this.lblFailureDetail.Text = errorText;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,120 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
|
@ -1,31 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using VizLauncher.com.raytheon.viz.launcher;
|
||||
|
||||
namespace VizLauncher
|
||||
{
|
||||
static class Program
|
||||
{
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main()
|
||||
{
|
||||
VizLauncher.com.raytheon.viz.launcher.VizLauncher vizLauncher =
|
||||
new VizLauncher.com.raytheon.viz.launcher.VizLauncher();
|
||||
bool success = vizLauncher.run(Application.StartupPath);
|
||||
if (success == false)
|
||||
{
|
||||
// Display the "Failure" dialog.
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
Application.Run(new Form1(vizLauncher.getErrorDetail()));
|
||||
}
|
||||
|
||||
Application.Exit();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,36 +0,0 @@
|
|||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("VizLauncher")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("Microsoft")]
|
||||
[assembly: AssemblyProduct("VizLauncher")]
|
||||
[assembly: AssemblyCopyright("Copyright © Microsoft 2013")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("7f929b46-b56e-47eb-b6e6-ff79e54f6572")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
|
@ -1,71 +0,0 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.17929
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace VizLauncher.Properties
|
||||
{
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// A strongly-typed resource class, for looking up localized strings, etc.
|
||||
/// </summary>
|
||||
// This class was auto-generated by the StronglyTypedResourceBuilder
|
||||
// class via a tool like ResGen or Visual Studio.
|
||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||
// with the /str option, or rebuild your VS project.
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Resources
|
||||
{
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the cached ResourceManager instance used by this class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager
|
||||
{
|
||||
get
|
||||
{
|
||||
if ((resourceMan == null))
|
||||
{
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("VizLauncher.Properties.Resources", typeof(Resources).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overrides the current thread's CurrentUICulture property for all
|
||||
/// resource lookups using this strongly typed resource class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture
|
||||
{
|
||||
get
|
||||
{
|
||||
return resourceCulture;
|
||||
}
|
||||
set
|
||||
{
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,117 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
|
@ -1,30 +0,0 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.17929
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace VizLauncher.Properties
|
||||
{
|
||||
|
||||
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.0.0")]
|
||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
|
||||
{
|
||||
|
||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||
|
||||
public static Settings Default
|
||||
{
|
||||
get
|
||||
{
|
||||
return defaultInstance;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
<?xml version='1.0' encoding='utf-8'?>
|
||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
||||
<Profiles>
|
||||
<Profile Name="(Default)" />
|
||||
</Profiles>
|
||||
<Settings />
|
||||
</SettingsFile>
|
|
@ -1,94 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
|
||||
<ProductVersion>8.0.30703</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{45B15612-0725-479C-8E1B-9B63F2FB45A3}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>VizLauncher</RootNamespace>
|
||||
<AssemblyName>VizLauncher</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
|
||||
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||
<PlatformTarget>x86</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Deployment" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="com\raytheon\viz\launcher\environment\EnvironmentProperties.cs" />
|
||||
<Compile Include="com\raytheon\viz\launcher\environment\VizEnvironment.cs" />
|
||||
<Compile Include="com\raytheon\viz\launcher\process\AbstractProcessLauncher.cs" />
|
||||
<Compile Include="com\raytheon\viz\launcher\process\impl\AlertvizProcessLauncher.cs" />
|
||||
<Compile Include="com\raytheon\viz\launcher\process\impl\CaveProcessLauncher.cs" />
|
||||
<Compile Include="com\raytheon\viz\launcher\process\IProcessLauncher.cs" />
|
||||
<Compile Include="com\raytheon\viz\launcher\VizLauncher.cs" />
|
||||
<Compile Include="Form1.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Form1.Designer.cs">
|
||||
<DependentUpon>Form1.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="Form1.resx">
|
||||
<DependentUpon>Form1.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Properties\Resources.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<Compile Include="Properties\Resources.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
</Compile>
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
</None>
|
||||
<Compile Include="Properties\Settings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
|
@ -1,3 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
</Project>
|
|
@ -1,68 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
using VizLauncher.com.raytheon.viz.launcher.environment;
|
||||
using VizLauncher.com.raytheon.viz.launcher.process;
|
||||
using VizLauncher.com.raytheon.viz.launcher.process.impl;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher
|
||||
{
|
||||
public class VizLauncher
|
||||
{
|
||||
private String errorDetail;
|
||||
|
||||
public bool run(String location)
|
||||
{
|
||||
VizEnvironment vizEnvironment = new VizEnvironment(location);
|
||||
if (vizEnvironment.isReady() == false)
|
||||
{
|
||||
this.errorDetail = vizEnvironment.getExceptionText();
|
||||
return false;
|
||||
}
|
||||
|
||||
/* Alternatively, we would be able to construct both process launchers using Spring and inject them. */
|
||||
|
||||
// Construct the AlertViz Process Launcher.
|
||||
IProcessLauncher alertvizProcessLauncher = new AlertvizProcessLauncher(vizEnvironment);
|
||||
if (alertvizProcessLauncher.isReady() == false)
|
||||
{
|
||||
this.errorDetail = alertvizProcessLauncher.getExceptionText();
|
||||
return false;
|
||||
}
|
||||
Thread alertvizThread = new Thread(alertvizProcessLauncher.launchProcess);
|
||||
|
||||
// Construct the CAVE Process Launcher.
|
||||
IProcessLauncher caveProcessLauncher = new CaveProcessLauncher(vizEnvironment);
|
||||
if (caveProcessLauncher.isReady() == false)
|
||||
{
|
||||
this.errorDetail = caveProcessLauncher.getExceptionText();
|
||||
return false;
|
||||
}
|
||||
Thread caveThread = new Thread(caveProcessLauncher.launchProcess);
|
||||
|
||||
// Start AlertViz.
|
||||
alertvizThread.Start();
|
||||
|
||||
// Delay - Give Alertviz Time To Start.
|
||||
Thread.Sleep(1000);
|
||||
|
||||
// Start CAVE.
|
||||
caveThread.Start();
|
||||
|
||||
// Wait for CAVE.
|
||||
caveThread.Join();
|
||||
|
||||
// Wait for AlertViz.
|
||||
alertvizThread.Join();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public String getErrorDetail()
|
||||
{
|
||||
return this.errorDetail;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,34 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.IO;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher.environment
|
||||
{
|
||||
public abstract class EnvironmentProperties
|
||||
{
|
||||
/* Environment Properties */
|
||||
public static readonly String USER_HOME_ENV_PROPERTY = "%HOMEDRIVE%%HOMEPATH%";
|
||||
public static readonly String COMPUTER_NAME_ENV_PROPERTY = "%COMPUTERNAME%";
|
||||
|
||||
/* Registry Constants */
|
||||
public static readonly String A2_JAVA_REG = @"Software\Raytheon\Runtime Environment\AWIPS II Java";
|
||||
public static readonly String A2_PYTHON_REG = @"Software\Raytheon\Runtime Environment\AWIPS II Python";
|
||||
|
||||
public static readonly String JAVA_JRE_VALUE_NAME = "JavaJreDirectory";
|
||||
public static readonly String PYTHON_INSTALL_NAME = "PythonInstallDirectory";
|
||||
|
||||
/* Environment Additions */
|
||||
public static readonly String ENVIRONMENT_VARIABLE_PATH = "Path";
|
||||
public static readonly String ENVIRONMENT_VARIABLE_PYTHON_PATH = "PythonPath";
|
||||
|
||||
public static readonly String PATH_PYTHON_DLLS = Path.DirectorySeparatorChar + "DLLs";
|
||||
public static readonly String PATH_JAVA_BIN = Path.DirectorySeparatorChar + "bin";
|
||||
|
||||
public static readonly String PYTHON_PATH_PYTHON_LIBTK =
|
||||
Path.DirectorySeparatorChar + "Lib" + Path.DirectorySeparatorChar + "lib-tk";
|
||||
public static readonly String PYTHON_PATH_PYTHON_DLLS = Path.DirectorySeparatorChar + "DLLs";
|
||||
public static readonly String PYTHON_PATH_PYTHON_LIB = Path.DirectorySeparatorChar + "Lib";
|
||||
}
|
||||
}
|
|
@ -1,137 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.IO;
|
||||
using Microsoft.Win32;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher.environment
|
||||
{
|
||||
public class VizEnvironment
|
||||
{
|
||||
private static readonly String CONSOLE_LOGS_DIRECTORY =
|
||||
Path.DirectorySeparatorChar + "caveData" + Path.DirectorySeparatorChar +
|
||||
"logs" + Path.DirectorySeparatorChar + "consoleLogs";
|
||||
private String location;
|
||||
private String logDirectory = null;
|
||||
private String path = null;
|
||||
private String pythonPath = null;
|
||||
|
||||
// did an error occur while initializing this object?
|
||||
private bool ready;
|
||||
// details about the error that has occurred.
|
||||
private String exceptionText;
|
||||
|
||||
public VizEnvironment(String location)
|
||||
{
|
||||
this.location = location;
|
||||
this.init();
|
||||
}
|
||||
|
||||
private void init()
|
||||
{
|
||||
/* For now we will assume that the environment properties will be available */
|
||||
// determine the location of the user's "home" directory.
|
||||
String homeDirectory =
|
||||
this.resolveEnvironmentProperty(EnvironmentProperties.USER_HOME_ENV_PROPERTY);
|
||||
|
||||
// determine the computer name.
|
||||
String computerName =
|
||||
this.resolveEnvironmentProperty(EnvironmentProperties.COMPUTER_NAME_ENV_PROPERTY);
|
||||
|
||||
// construct the path to the log directory.
|
||||
this.logDirectory = homeDirectory + CONSOLE_LOGS_DIRECTORY +
|
||||
Path.DirectorySeparatorChar + computerName;
|
||||
|
||||
// retrieve the jdk directory from the registry.
|
||||
String jdkDirectory =
|
||||
this.retrieveRegistryProperty(EnvironmentProperties.A2_JAVA_REG,
|
||||
EnvironmentProperties.JAVA_JRE_VALUE_NAME);
|
||||
if (jdkDirectory == null)
|
||||
{
|
||||
this.notReady("Unable to retrieve the Java JDK Path from the registry!");
|
||||
return;
|
||||
}
|
||||
|
||||
// retrieve the python location from the registry.
|
||||
String pythonLocation =
|
||||
this.retrieveRegistryProperty(EnvironmentProperties.A2_PYTHON_REG,
|
||||
EnvironmentProperties.PYTHON_INSTALL_NAME);
|
||||
if (pythonLocation == null)
|
||||
{
|
||||
this.notReady("Unable to retrieve the Python Install Location from the registry!");
|
||||
return;
|
||||
}
|
||||
|
||||
// Construct the PATH.
|
||||
this.path = pythonLocation + Path.PathSeparator;
|
||||
this.path += pythonLocation + EnvironmentProperties.PATH_PYTHON_DLLS + Path.PathSeparator;
|
||||
this.path += jdkDirectory + EnvironmentProperties.PATH_JAVA_BIN;
|
||||
|
||||
// Construct the PYTHON_PATH.
|
||||
this.pythonPath = pythonLocation + EnvironmentProperties.PYTHON_PATH_PYTHON_LIBTK + Path.PathSeparator;
|
||||
this.pythonPath += pythonLocation + EnvironmentProperties.PYTHON_PATH_PYTHON_DLLS + Path.PathSeparator;
|
||||
this.pythonPath += pythonLocation + EnvironmentProperties.PYTHON_PATH_PYTHON_LIB + Path.PathSeparator;
|
||||
this.pythonPath += pythonLocation;
|
||||
|
||||
this.ready = true;
|
||||
}
|
||||
|
||||
private String resolveEnvironmentProperty(String property)
|
||||
{
|
||||
return Environment.ExpandEnvironmentVariables(property);
|
||||
}
|
||||
|
||||
private String retrieveRegistryProperty(String registryKeyName, String valueName)
|
||||
{
|
||||
RegistryKey registryKey = Registry.LocalMachine.OpenSubKey(registryKeyName);
|
||||
if (registryKey == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
Object registryValue = registryKey.GetValue(valueName, null);
|
||||
if (registryValue == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return registryValue.ToString();
|
||||
}
|
||||
|
||||
private void notReady(String reason)
|
||||
{
|
||||
this.ready = false;
|
||||
this.exceptionText = reason;
|
||||
}
|
||||
|
||||
public String getLocation()
|
||||
{
|
||||
return this.location;
|
||||
}
|
||||
|
||||
public String getLogDirectory()
|
||||
{
|
||||
return this.logDirectory;
|
||||
}
|
||||
|
||||
public String getPath()
|
||||
{
|
||||
return this.path;
|
||||
}
|
||||
|
||||
public String getPythonPath()
|
||||
{
|
||||
return this.pythonPath;
|
||||
}
|
||||
|
||||
public bool isReady()
|
||||
{
|
||||
return this.ready;
|
||||
}
|
||||
|
||||
public String getExceptionText()
|
||||
{
|
||||
return this.exceptionText;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,137 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.IO;
|
||||
using System.Diagnostics;
|
||||
using VizLauncher.com.raytheon.viz.launcher.environment;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher.process
|
||||
{
|
||||
public abstract class AbstractProcessLauncher : IProcessLauncher
|
||||
{
|
||||
private static readonly String LOG_DATE_FORMAT = "yyyyMMdd_HHmmss";
|
||||
protected static readonly String LOG_SUFFIX = ".log";
|
||||
protected Process process = null;
|
||||
private StreamWriter logFileWriter;
|
||||
protected VizEnvironment vizEnvironment;
|
||||
|
||||
private bool ready = false;
|
||||
private String exceptionText = null;
|
||||
|
||||
public AbstractProcessLauncher(VizEnvironment vizEnvironment)
|
||||
{
|
||||
this.vizEnvironment = vizEnvironment;
|
||||
// Prepare the log file.
|
||||
if (Directory.Exists(vizEnvironment.getLogDirectory()) == false)
|
||||
{
|
||||
Directory.CreateDirectory(vizEnvironment.getLogDirectory());
|
||||
}
|
||||
String logName = vizEnvironment.getLogDirectory() +
|
||||
Path.DirectorySeparatorChar + this.constructLogName(this.determineLogDate());
|
||||
|
||||
// Prepare the process.
|
||||
this.process = new Process();
|
||||
this.process.StartInfo = this.constructProcessStartInfo(vizEnvironment);
|
||||
this.process.OutputDataReceived += new DataReceivedEventHandler(processOutputHandler);
|
||||
this.validate();
|
||||
if (this.ready == false)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
* Access the log file for write access; other processes will have read-only access to
|
||||
* the log file until it is closed.
|
||||
**/
|
||||
this.logFileWriter =
|
||||
new StreamWriter(File.Open(logName, FileMode.Append,
|
||||
FileAccess.Write, FileShare.Read));
|
||||
}
|
||||
|
||||
private String determineLogDate()
|
||||
{
|
||||
return DateTime.Now.ToString(LOG_DATE_FORMAT);
|
||||
}
|
||||
|
||||
private ProcessStartInfo constructProcessStartInfo(VizEnvironment vizEnvironment)
|
||||
{
|
||||
ProcessStartInfo processStartInfo =
|
||||
new ProcessStartInfo(this.constructProcessName(vizEnvironment.getLocation()));
|
||||
// include the default system PATH in the application PATH
|
||||
String systemPath = System.Environment.GetEnvironmentVariable("PATH");
|
||||
processStartInfo.EnvironmentVariables[EnvironmentProperties.ENVIRONMENT_VARIABLE_PATH] =
|
||||
vizEnvironment.getPath() + this.getApplicationSpecificPath() + systemPath;
|
||||
processStartInfo.EnvironmentVariables[EnvironmentProperties.ENVIRONMENT_VARIABLE_PYTHON_PATH] =
|
||||
vizEnvironment.getPythonPath();
|
||||
processStartInfo.UseShellExecute = false;
|
||||
processStartInfo.Arguments = this.getCommandLineArguments();
|
||||
processStartInfo.RedirectStandardOutput = true;
|
||||
|
||||
return processStartInfo;
|
||||
}
|
||||
|
||||
protected void validate()
|
||||
{
|
||||
String application = this.process.StartInfo.FileName;
|
||||
/* ensure that the specified application exists. */
|
||||
if (File.Exists(application) == false)
|
||||
{
|
||||
this.ready = false;
|
||||
this.exceptionText = "Unable to find the specified Viz application: " + application;
|
||||
return;
|
||||
}
|
||||
|
||||
this.ready = true;
|
||||
}
|
||||
|
||||
public virtual void launchProcess()
|
||||
{
|
||||
this.runProcess();
|
||||
this.closeLog();
|
||||
}
|
||||
|
||||
protected void runProcess()
|
||||
{
|
||||
this.process.Start();
|
||||
this.process.BeginOutputReadLine();
|
||||
this.process.WaitForExit();
|
||||
this.process.CancelOutputRead();
|
||||
}
|
||||
|
||||
protected void closeLog()
|
||||
{
|
||||
this.logFileWriter.Close();
|
||||
}
|
||||
|
||||
private void processOutputHandler(Object sendingProcess, DataReceivedEventArgs outline)
|
||||
{
|
||||
if (String.IsNullOrEmpty(outline.Data))
|
||||
{
|
||||
return;
|
||||
}
|
||||
this.logFileWriter.WriteLine(outline.Data);
|
||||
}
|
||||
|
||||
public bool isReady()
|
||||
{
|
||||
return this.ready;
|
||||
}
|
||||
|
||||
public String getExceptionText()
|
||||
{
|
||||
return this.exceptionText;
|
||||
}
|
||||
|
||||
protected virtual String getApplicationSpecificPath()
|
||||
{
|
||||
return String.Empty;
|
||||
}
|
||||
|
||||
protected abstract String constructProcessName(String location);
|
||||
|
||||
protected abstract String constructLogName(String logDate);
|
||||
|
||||
protected abstract String getCommandLineArguments();
|
||||
}
|
||||
}
|
|
@ -1,16 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher.process
|
||||
{
|
||||
public interface IProcessLauncher
|
||||
{
|
||||
void launchProcess();
|
||||
|
||||
bool isReady();
|
||||
String getExceptionText();
|
||||
}
|
||||
}
|
|
@ -1,62 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using VizLauncher.com.raytheon.viz.launcher.process;
|
||||
using VizLauncher.com.raytheon.viz.launcher.environment;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher.process.impl
|
||||
{
|
||||
public class AlertvizProcessLauncher : AbstractProcessLauncher
|
||||
{
|
||||
private static readonly String LOG_PREFIX = "alertviz_";
|
||||
private static readonly String COMMAND_LINE_ARGUMENTS = "-component thinalertviz";
|
||||
private static readonly String ALERTVIZ_PROCESS_NAME = "alertviz";
|
||||
private static readonly String ALERTVIZ_EXECUTABLE =
|
||||
Path.DirectorySeparatorChar + "AlertViz" +
|
||||
Path.DirectorySeparatorChar + "alertviz.exe";
|
||||
|
||||
public AlertvizProcessLauncher(VizEnvironment vizEnvironment) : base(vizEnvironment)
|
||||
{
|
||||
}
|
||||
|
||||
public override void launchProcess()
|
||||
{
|
||||
// need to verify that another AlertViz process is not already running.
|
||||
if (this.isAlertVizAlreadyRunning())
|
||||
{
|
||||
// do not start a new AlertViz process.
|
||||
return;
|
||||
}
|
||||
|
||||
this.runProcess();
|
||||
while (this.process.ExitCode != 0)
|
||||
{
|
||||
this.runProcess();
|
||||
}
|
||||
this.closeLog();
|
||||
}
|
||||
|
||||
private Boolean isAlertVizAlreadyRunning()
|
||||
{
|
||||
return (Process.GetProcessesByName(ALERTVIZ_PROCESS_NAME).Length > 0);
|
||||
}
|
||||
|
||||
protected override String constructProcessName(String location)
|
||||
{
|
||||
return location + ALERTVIZ_EXECUTABLE;
|
||||
}
|
||||
|
||||
protected override String constructLogName(String logDate)
|
||||
{
|
||||
return LOG_PREFIX + logDate + AbstractProcessLauncher.LOG_SUFFIX;
|
||||
}
|
||||
|
||||
protected override String getCommandLineArguments()
|
||||
{
|
||||
return COMMAND_LINE_ARGUMENTS;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,45 +0,0 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.IO;
|
||||
using VizLauncher.com.raytheon.viz.launcher.process;
|
||||
using VizLauncher.com.raytheon.viz.launcher.environment;
|
||||
|
||||
namespace VizLauncher.com.raytheon.viz.launcher.process.impl
|
||||
{
|
||||
public class CaveProcessLauncher : AbstractProcessLauncher
|
||||
{
|
||||
private static readonly String LOG_PREFIX = "cave_";
|
||||
private static readonly String COMMAND_LINE_ARGUMENTS = "-component thinclient";
|
||||
private static readonly String CAVE_DIRECTORY = Path.DirectorySeparatorChar + "CAVE";
|
||||
private static readonly String CAVE_EXECUTABLE =
|
||||
CAVE_DIRECTORY + Path.DirectorySeparatorChar + "cave.exe";
|
||||
|
||||
public CaveProcessLauncher(VizEnvironment vizEnvironment)
|
||||
: base(vizEnvironment)
|
||||
{
|
||||
}
|
||||
|
||||
protected override String getApplicationSpecificPath()
|
||||
{
|
||||
return Path.PathSeparator + this.vizEnvironment.getLocation() +
|
||||
CAVE_DIRECTORY + Path.DirectorySeparatorChar + "lib" + Path.PathSeparator;
|
||||
}
|
||||
|
||||
protected override String constructProcessName(String location)
|
||||
{
|
||||
return location + CAVE_EXECUTABLE;
|
||||
}
|
||||
|
||||
protected override String constructLogName(String logDate)
|
||||
{
|
||||
return LOG_PREFIX + logDate + AbstractProcessLauncher.LOG_SUFFIX;
|
||||
}
|
||||
|
||||
protected override String getCommandLineArguments()
|
||||
{
|
||||
return COMMAND_LINE_ARGUMENTS;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue