Recovered from cvs revision 2007-04-29 16:11:00
This commit is contained in:
@ -1,420 +0,0 @@
|
||||
/*
|
||||
* $Id: Awk.cs,v 1.1 2007/09/03 03:50:39 bacon Exp $
|
||||
*/
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.IO;
|
||||
|
||||
using COM = System.Runtime.InteropServices.ComTypes;
|
||||
|
||||
namespace ase.com
|
||||
{
|
||||
public class Awk : ASECOM.IAwkEvents
|
||||
{
|
||||
private ASECOM.Awk awk;
|
||||
|
||||
private int cookie = -1;
|
||||
private COM.IConnectionPoint icp;
|
||||
|
||||
private Stream sourceInputStream = null;
|
||||
private Stream sourceOutputStream = null;
|
||||
private StreamReader sourceInputReader;
|
||||
private StreamWriter sourceOutputWriter;
|
||||
|
||||
private Stream consoleInputStream = null;
|
||||
private Stream consoleOutputStream = null;
|
||||
private StreamReader consoleInputReader;
|
||||
private StreamWriter consoleOutputWriter;
|
||||
|
||||
public delegate object FunctionHandler (object[] args);
|
||||
private System.Collections.Hashtable funcTable;
|
||||
|
||||
char[] consoleInputBuffer = new char[1024];
|
||||
|
||||
public Awk()
|
||||
{
|
||||
this.funcTable = new System.Collections.Hashtable();
|
||||
|
||||
this.awk = new ASECOM.Awk();
|
||||
this.awk.UseLongLong = true;
|
||||
//this.awk.UseCrlf = true;
|
||||
|
||||
COM.IConnectionPointContainer icpc =
|
||||
(COM.IConnectionPointContainer)awk;
|
||||
Guid g = typeof(ASECOM.IAwkEvents).GUID;
|
||||
|
||||
try
|
||||
{
|
||||
icpc.FindConnectionPoint(ref g, out icp);
|
||||
icp.Advise(this, out this.cookie);
|
||||
}
|
||||
catch (System.Runtime.InteropServices.COMException ex)
|
||||
{
|
||||
this.cookie = -1;
|
||||
//System.Windows.Forms.MessageBox.Show(ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
/*~Awk()
|
||||
{
|
||||
if (cookie != -1 && icp != null)
|
||||
{
|
||||
try
|
||||
{
|
||||
icp.Unadvise(cookie);
|
||||
cookie = -1;
|
||||
}
|
||||
catch (System.Runtime.InteropServices.COMException ex)
|
||||
{
|
||||
System.Windows.Forms.MessageBox.Show(ex.Message);
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
public int ErrorCode
|
||||
{
|
||||
get { return awk.ErrorCode; }
|
||||
}
|
||||
|
||||
public int ErrorLine
|
||||
{
|
||||
get { return awk.ErrorLine; }
|
||||
}
|
||||
|
||||
public string ErrorMessage
|
||||
{
|
||||
get { return awk.ErrorMessage; }
|
||||
}
|
||||
|
||||
public bool ImplicitVariable
|
||||
{
|
||||
get { return awk.ImplicitVariable; }
|
||||
set { awk.ImplicitVariable = value; }
|
||||
}
|
||||
|
||||
public bool ExplicitVariable
|
||||
{
|
||||
get { return awk.ExplicitVariable; }
|
||||
set { awk.ExplicitVariable = value; }
|
||||
}
|
||||
|
||||
public bool UniqueFunction
|
||||
{
|
||||
get { return awk.UniqueFunction; }
|
||||
set { awk.UniqueFunction = value; }
|
||||
}
|
||||
|
||||
public bool VariableShading
|
||||
{
|
||||
get { return awk.VariableShading; }
|
||||
set { awk.VariableShading = value; }
|
||||
}
|
||||
|
||||
public bool ShiftOperators
|
||||
{
|
||||
get { return awk.ShiftOperators; }
|
||||
set { awk.ShiftOperators = value; }
|
||||
}
|
||||
|
||||
public bool IdivOperator
|
||||
{
|
||||
get { return awk.IdivOperator; }
|
||||
set { awk.IdivOperator = value; }
|
||||
}
|
||||
|
||||
public bool ConcatString
|
||||
{
|
||||
get { return awk.ConcatString; }
|
||||
set { awk.ConcatString = value; }
|
||||
}
|
||||
|
||||
public bool SupportExtio
|
||||
{
|
||||
get { return awk.SupportExtio; }
|
||||
set { awk.SupportExtio = value; }
|
||||
}
|
||||
|
||||
public bool SupportBlockless
|
||||
{
|
||||
get { return awk.SupportBlockless; }
|
||||
set { awk.SupportBlockless = value; }
|
||||
}
|
||||
|
||||
public bool StringBaseOne
|
||||
{
|
||||
get { return awk.StringBaseOne; }
|
||||
set { awk.StringBaseOne = value; }
|
||||
}
|
||||
|
||||
public bool StripSpaces
|
||||
{
|
||||
get { return awk.StripSpaces; }
|
||||
set { awk.StripSpaces = value; }
|
||||
}
|
||||
|
||||
public bool Nextofile
|
||||
{
|
||||
get { return awk.Nextofile; }
|
||||
set { awk.Nextofile = value; }
|
||||
}
|
||||
|
||||
public bool Usecrlf
|
||||
{
|
||||
get { return awk.UseCrlf; }
|
||||
set { awk.UseCrlf = value; }
|
||||
}
|
||||
|
||||
public string EntryPoint
|
||||
{
|
||||
get { return awk.EntryPoint; }
|
||||
set { awk.EntryPoint = value; }
|
||||
}
|
||||
|
||||
public bool ArgumentsToEntryPoint
|
||||
{
|
||||
get { return awk.ArgumentsToEntryPoint; }
|
||||
set { awk.ArgumentsToEntryPoint = value; }
|
||||
}
|
||||
|
||||
public bool Debug
|
||||
{
|
||||
get { return awk.Debug; }
|
||||
set { awk.Debug = value; }
|
||||
}
|
||||
|
||||
/* this property doesn't need to be available to the public
|
||||
* as it can be always true in .NET environment. However,
|
||||
* it is kept private here for reference */
|
||||
private bool UseLongLong
|
||||
{
|
||||
get { return awk.UseLongLong; }
|
||||
set { awk.UseLongLong = value; }
|
||||
}
|
||||
|
||||
public int MaxDepthForBlockParse
|
||||
{
|
||||
get { return awk.MaxDepthForBlockParse; }
|
||||
set { awk.MaxDepthForBlockParse = value; }
|
||||
}
|
||||
|
||||
public int MaxDepthForBlockRun
|
||||
{
|
||||
get { return awk.MaxDepthForBlockRun; }
|
||||
set { awk.MaxDepthForBlockRun = value; }
|
||||
}
|
||||
|
||||
public int MaxDepthForExprParse
|
||||
{
|
||||
get { return awk.MaxDepthForExprParse; }
|
||||
set { awk.MaxDepthForExprParse = value; }
|
||||
}
|
||||
|
||||
public int MaxDepthForExprRun
|
||||
{
|
||||
get { return awk.MaxDepthForExprRun; }
|
||||
set { awk.MaxDepthForExprRun = value; }
|
||||
}
|
||||
|
||||
public int MaxDepthForRexBuild
|
||||
{
|
||||
get { return awk.MaxDepthForRexBuild; }
|
||||
set { awk.MaxDepthForRexBuild = value; }
|
||||
}
|
||||
|
||||
public int MaxDepthForRexMatch
|
||||
{
|
||||
get { return awk.MaxDepthForRexMatch; }
|
||||
set { awk.MaxDepthForRexMatch = value; }
|
||||
}
|
||||
|
||||
public virtual bool AddFunction(string name, int minArgs, int maxArgs, FunctionHandler handler)
|
||||
{
|
||||
if (funcTable.ContainsKey(name)) return false;
|
||||
|
||||
funcTable.Add(name, handler);
|
||||
if (!awk.AddFunction(name, minArgs, maxArgs))
|
||||
{
|
||||
funcTable.Remove(name);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public virtual bool DeleteFunction(string name)
|
||||
{
|
||||
if (!funcTable.ContainsKey(name)) return false;
|
||||
|
||||
if (awk.DeleteFunction(name))
|
||||
{
|
||||
funcTable.Remove(name);
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
public virtual bool Parse()
|
||||
{
|
||||
return awk.Parse();
|
||||
}
|
||||
|
||||
public virtual bool Run ()
|
||||
{
|
||||
return awk.Run(null);
|
||||
}
|
||||
|
||||
public virtual bool Run(string[] args)
|
||||
{
|
||||
return awk.Run(args);
|
||||
}
|
||||
|
||||
public Stream SourceInputStream
|
||||
{
|
||||
get { return this.sourceInputStream; }
|
||||
set { this.sourceInputStream = value; }
|
||||
}
|
||||
|
||||
public Stream SourceOutputStream
|
||||
{
|
||||
get { return this.sourceOutputStream; }
|
||||
set { this.sourceOutputStream = value; }
|
||||
}
|
||||
|
||||
public Stream ConsoleInputStream
|
||||
{
|
||||
get { return this.consoleInputStream; }
|
||||
set { this.consoleInputStream = value; }
|
||||
}
|
||||
|
||||
public Stream ConsoleOutputStream
|
||||
{
|
||||
get { return this.consoleOutputStream; }
|
||||
set { this.consoleOutputStream = value; }
|
||||
}
|
||||
|
||||
public virtual int OpenSource(ASECOM.AwkSourceMode mode)
|
||||
{
|
||||
if (mode == ASECOM.AwkSourceMode.AWK_SOURCE_READ)
|
||||
{
|
||||
if (this.sourceInputStream == null) return 0;
|
||||
this.sourceInputReader = new StreamReader (this.sourceInputStream);
|
||||
return 1;
|
||||
}
|
||||
else if (mode == ASECOM.AwkSourceMode.AWK_SOURCE_WRITE)
|
||||
{
|
||||
if (this.sourceOutputStream == null) return 0;
|
||||
this.sourceOutputWriter = new StreamWriter (this.sourceOutputStream);
|
||||
return 1;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int CloseSource(ASECOM.AwkSourceMode mode)
|
||||
{
|
||||
if (mode == ASECOM.AwkSourceMode.AWK_SOURCE_READ)
|
||||
{
|
||||
this.sourceInputReader.Close ();
|
||||
return 0;
|
||||
}
|
||||
else if (mode == ASECOM.AwkSourceMode.AWK_SOURCE_WRITE)
|
||||
{
|
||||
this.sourceOutputWriter.Close ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int ReadSource(ASECOM.Buffer buf)
|
||||
{
|
||||
buf.Value = this.sourceInputReader.ReadLine();
|
||||
if (buf.Value == null) return 0;
|
||||
return buf.Value.Length;
|
||||
}
|
||||
|
||||
public virtual int WriteSource(ASECOM.Buffer buf)
|
||||
{
|
||||
this.sourceOutputWriter.Write(buf.Value);
|
||||
return buf.Value.Length;
|
||||
}
|
||||
|
||||
public virtual int OpenExtio(ASECOM.AwkExtio extio)
|
||||
{
|
||||
if (extio.Mode == ASECOM.AwkExtioMode.AWK_EXTIO_CONSOLE_READ)
|
||||
{
|
||||
if (this.consoleInputStream == null) return 0;
|
||||
this.consoleInputReader = new StreamReader(this.consoleInputStream);
|
||||
return 1;
|
||||
}
|
||||
else if (extio.Mode == ASECOM.AwkExtioMode.AWK_EXTIO_CONSOLE_WRITE)
|
||||
{
|
||||
if (this.consoleOutputStream == null) return 0;
|
||||
this.consoleOutputWriter = new StreamWriter(this.consoleOutputStream);
|
||||
return 1;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int CloseExtio(ASECOM.AwkExtio extio)
|
||||
{
|
||||
if (extio.Mode == ASECOM.AwkExtioMode.AWK_EXTIO_CONSOLE_READ)
|
||||
{
|
||||
this.consoleInputReader.Close();
|
||||
return 0;
|
||||
}
|
||||
else if (extio.Mode == ASECOM.AwkExtioMode.AWK_EXTIO_CONSOLE_WRITE)
|
||||
{
|
||||
this.consoleOutputWriter.Close();
|
||||
return 0;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int ReadExtio(ASECOM.AwkExtio extio, ASECOM.Buffer buf)
|
||||
{
|
||||
if (extio.Mode == ASECOM.AwkExtioMode.AWK_EXTIO_CONSOLE_READ)
|
||||
{
|
||||
int n = this.consoleInputReader.Read(consoleInputBuffer, 0, consoleInputBuffer.Length);
|
||||
if (n == 0) return 0;
|
||||
buf.Value = new string(consoleInputBuffer, 0, n);
|
||||
return buf.Value.Length;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int WriteExtio(ASECOM.AwkExtio extio, ASECOM.Buffer buf)
|
||||
{
|
||||
if (extio.Mode == ASECOM.AwkExtioMode.AWK_EXTIO_CONSOLE_WRITE)
|
||||
{
|
||||
this.consoleOutputWriter.Write(buf.Value);
|
||||
return buf.Value.Length;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int FlushExtio(ASECOM.AwkExtio extio)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
public virtual int NextExtio(ASECOM.AwkExtio extio)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
public virtual object HandleFunction(string name, object argarray)
|
||||
{
|
||||
FunctionHandler handler = (FunctionHandler)funcTable[name];
|
||||
return handler((object[])argarray);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
381
ase/test/com/AwkForm.Designer.cs
generated
381
ase/test/com/AwkForm.Designer.cs
generated
@ -1,381 +0,0 @@
|
||||
namespace ase.com
|
||||
{
|
||||
partial class AwkForm
|
||||
{
|
||||
/// <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.tbxSourceInput = new System.Windows.Forms.TextBox();
|
||||
this.btnRun = new System.Windows.Forms.Button();
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.panel1 = new System.Windows.Forms.Panel();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.panel3 = new System.Windows.Forms.Panel();
|
||||
this.tbxSourceOutput = new System.Windows.Forms.TextBox();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.panel4 = new System.Windows.Forms.Panel();
|
||||
this.tbxConsoleInput = new System.Windows.Forms.TextBox();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.panel5 = new System.Windows.Forms.Panel();
|
||||
this.tbxConsoleOutput = new System.Windows.Forms.TextBox();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.statusStrip1 = new System.Windows.Forms.StatusStrip();
|
||||
this.cbxEntryPoint = new System.Windows.Forms.ComboBox();
|
||||
this.panel2 = new System.Windows.Forms.Panel();
|
||||
this.groupBox2 = new System.Windows.Forms.GroupBox();
|
||||
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
||||
this.chkPassArgumentsToEntryPoint = new System.Windows.Forms.CheckBox();
|
||||
this.btnClearAllArguments = new System.Windows.Forms.Button();
|
||||
this.btnAddArgument = new System.Windows.Forms.Button();
|
||||
this.tbxArgument = new System.Windows.Forms.TextBox();
|
||||
this.lbxArguments = new System.Windows.Forms.ListBox();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.panel1.SuspendLayout();
|
||||
this.panel3.SuspendLayout();
|
||||
this.panel4.SuspendLayout();
|
||||
this.panel5.SuspendLayout();
|
||||
this.panel2.SuspendLayout();
|
||||
this.groupBox2.SuspendLayout();
|
||||
this.groupBox1.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// tbxSourceInput
|
||||
//
|
||||
this.tbxSourceInput.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tbxSourceInput.Location = new System.Drawing.Point(0, 19);
|
||||
this.tbxSourceInput.Multiline = true;
|
||||
this.tbxSourceInput.Name = "tbxSourceInput";
|
||||
this.tbxSourceInput.ScrollBars = System.Windows.Forms.ScrollBars.Both;
|
||||
this.tbxSourceInput.Size = new System.Drawing.Size(240, 230);
|
||||
this.tbxSourceInput.TabIndex = 1;
|
||||
this.tbxSourceInput.WordWrap = false;
|
||||
//
|
||||
// btnRun
|
||||
//
|
||||
this.btnRun.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.btnRun.Location = new System.Drawing.Point(76, 303);
|
||||
this.btnRun.Name = "btnRun";
|
||||
this.btnRun.Size = new System.Drawing.Size(75, 23);
|
||||
this.btnRun.TabIndex = 2;
|
||||
this.btnRun.Text = "Run";
|
||||
this.btnRun.UseVisualStyleBackColor = true;
|
||||
this.btnRun.Click += new System.EventHandler(this.btnRun_Click);
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.ColumnCount = 2;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.panel1, 0, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.panel3, 1, 0);
|
||||
this.tableLayoutPanel1.Controls.Add(this.panel4, 0, 1);
|
||||
this.tableLayoutPanel1.Controls.Add(this.panel5, 1, 1);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(157, 0);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.RowCount = 2;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(492, 510);
|
||||
this.tableLayoutPanel1.TabIndex = 2;
|
||||
//
|
||||
// panel1
|
||||
//
|
||||
this.panel1.Controls.Add(this.tbxSourceInput);
|
||||
this.panel1.Controls.Add(this.label1);
|
||||
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.panel1.Location = new System.Drawing.Point(3, 3);
|
||||
this.panel1.Name = "panel1";
|
||||
this.panel1.Size = new System.Drawing.Size(240, 249);
|
||||
this.panel1.TabIndex = 5;
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.label1.Location = new System.Drawing.Point(0, 0);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
|
||||
this.label1.Size = new System.Drawing.Size(68, 19);
|
||||
this.label1.TabIndex = 2;
|
||||
this.label1.Text = "Source Input";
|
||||
//
|
||||
// panel3
|
||||
//
|
||||
this.panel3.Controls.Add(this.tbxSourceOutput);
|
||||
this.panel3.Controls.Add(this.label2);
|
||||
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.panel3.Location = new System.Drawing.Point(249, 3);
|
||||
this.panel3.Name = "panel3";
|
||||
this.panel3.Size = new System.Drawing.Size(240, 249);
|
||||
this.panel3.TabIndex = 6;
|
||||
//
|
||||
// tbxSourceOutput
|
||||
//
|
||||
this.tbxSourceOutput.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tbxSourceOutput.Location = new System.Drawing.Point(0, 19);
|
||||
this.tbxSourceOutput.Multiline = true;
|
||||
this.tbxSourceOutput.Name = "tbxSourceOutput";
|
||||
this.tbxSourceOutput.ReadOnly = true;
|
||||
this.tbxSourceOutput.ScrollBars = System.Windows.Forms.ScrollBars.Both;
|
||||
this.tbxSourceOutput.Size = new System.Drawing.Size(240, 230);
|
||||
this.tbxSourceOutput.TabIndex = 2;
|
||||
this.tbxSourceOutput.WordWrap = false;
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.label2.Location = new System.Drawing.Point(0, 0);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
|
||||
this.label2.Size = new System.Drawing.Size(76, 19);
|
||||
this.label2.TabIndex = 0;
|
||||
this.label2.Text = "Source Output";
|
||||
//
|
||||
// panel4
|
||||
//
|
||||
this.panel4.Controls.Add(this.tbxConsoleInput);
|
||||
this.panel4.Controls.Add(this.label3);
|
||||
this.panel4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.panel4.Location = new System.Drawing.Point(3, 258);
|
||||
this.panel4.Name = "panel4";
|
||||
this.panel4.Size = new System.Drawing.Size(240, 249);
|
||||
this.panel4.TabIndex = 7;
|
||||
//
|
||||
// tbxConsoleInput
|
||||
//
|
||||
this.tbxConsoleInput.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tbxConsoleInput.Location = new System.Drawing.Point(0, 19);
|
||||
this.tbxConsoleInput.Multiline = true;
|
||||
this.tbxConsoleInput.Name = "tbxConsoleInput";
|
||||
this.tbxConsoleInput.ScrollBars = System.Windows.Forms.ScrollBars.Both;
|
||||
this.tbxConsoleInput.Size = new System.Drawing.Size(240, 230);
|
||||
this.tbxConsoleInput.TabIndex = 3;
|
||||
this.tbxConsoleInput.WordWrap = false;
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.label3.Location = new System.Drawing.Point(0, 0);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
|
||||
this.label3.Size = new System.Drawing.Size(72, 19);
|
||||
this.label3.TabIndex = 0;
|
||||
this.label3.Text = "Console Input";
|
||||
//
|
||||
// panel5
|
||||
//
|
||||
this.panel5.Controls.Add(this.tbxConsoleOutput);
|
||||
this.panel5.Controls.Add(this.label4);
|
||||
this.panel5.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.panel5.Location = new System.Drawing.Point(249, 258);
|
||||
this.panel5.Name = "panel5";
|
||||
this.panel5.Size = new System.Drawing.Size(240, 249);
|
||||
this.panel5.TabIndex = 8;
|
||||
//
|
||||
// tbxConsoleOutput
|
||||
//
|
||||
this.tbxConsoleOutput.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tbxConsoleOutput.Location = new System.Drawing.Point(0, 19);
|
||||
this.tbxConsoleOutput.Multiline = true;
|
||||
this.tbxConsoleOutput.Name = "tbxConsoleOutput";
|
||||
this.tbxConsoleOutput.ReadOnly = true;
|
||||
this.tbxConsoleOutput.ScrollBars = System.Windows.Forms.ScrollBars.Both;
|
||||
this.tbxConsoleOutput.Size = new System.Drawing.Size(240, 230);
|
||||
this.tbxConsoleOutput.TabIndex = 4;
|
||||
this.tbxConsoleOutput.WordWrap = false;
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.label4.Location = new System.Drawing.Point(0, 0);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
|
||||
this.label4.Size = new System.Drawing.Size(80, 19);
|
||||
this.label4.TabIndex = 0;
|
||||
this.label4.Text = "Console Output";
|
||||
//
|
||||
// statusStrip1
|
||||
//
|
||||
this.statusStrip1.Location = new System.Drawing.Point(0, 510);
|
||||
this.statusStrip1.Name = "statusStrip1";
|
||||
this.statusStrip1.Size = new System.Drawing.Size(649, 22);
|
||||
this.statusStrip1.TabIndex = 3;
|
||||
this.statusStrip1.Text = "statusStrip1";
|
||||
//
|
||||
// cbxEntryPoint
|
||||
//
|
||||
this.cbxEntryPoint.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.cbxEntryPoint.FormattingEnabled = true;
|
||||
this.cbxEntryPoint.Location = new System.Drawing.Point(3, 16);
|
||||
this.cbxEntryPoint.Name = "cbxEntryPoint";
|
||||
this.cbxEntryPoint.Size = new System.Drawing.Size(147, 21);
|
||||
this.cbxEntryPoint.TabIndex = 1;
|
||||
//
|
||||
// panel2
|
||||
//
|
||||
this.panel2.AutoScroll = true;
|
||||
this.panel2.Controls.Add(this.btnRun);
|
||||
this.panel2.Controls.Add(this.groupBox2);
|
||||
this.panel2.Controls.Add(this.groupBox1);
|
||||
this.panel2.Dock = System.Windows.Forms.DockStyle.Left;
|
||||
this.panel2.Location = new System.Drawing.Point(0, 0);
|
||||
this.panel2.Name = "panel2";
|
||||
this.panel2.Size = new System.Drawing.Size(157, 510);
|
||||
this.panel2.TabIndex = 5;
|
||||
//
|
||||
// groupBox2
|
||||
//
|
||||
this.groupBox2.Controls.Add(this.cbxEntryPoint);
|
||||
this.groupBox2.Location = new System.Drawing.Point(0, 4);
|
||||
this.groupBox2.Name = "groupBox2";
|
||||
this.groupBox2.Size = new System.Drawing.Size(153, 45);
|
||||
this.groupBox2.TabIndex = 1;
|
||||
this.groupBox2.TabStop = false;
|
||||
this.groupBox2.Text = "Entry Point";
|
||||
//
|
||||
// groupBox1
|
||||
//
|
||||
this.groupBox1.AutoSize = true;
|
||||
this.groupBox1.Controls.Add(this.chkPassArgumentsToEntryPoint);
|
||||
this.groupBox1.Controls.Add(this.btnClearAllArguments);
|
||||
this.groupBox1.Controls.Add(this.btnAddArgument);
|
||||
this.groupBox1.Controls.Add(this.tbxArgument);
|
||||
this.groupBox1.Controls.Add(this.lbxArguments);
|
||||
this.groupBox1.Location = new System.Drawing.Point(0, 51);
|
||||
this.groupBox1.Name = "groupBox1";
|
||||
this.groupBox1.Size = new System.Drawing.Size(154, 247);
|
||||
this.groupBox1.TabIndex = 0;
|
||||
this.groupBox1.TabStop = false;
|
||||
this.groupBox1.Text = "Arguments";
|
||||
//
|
||||
// chkPassArgumentsToEntryPoint
|
||||
//
|
||||
this.chkPassArgumentsToEntryPoint.AutoSize = true;
|
||||
this.chkPassArgumentsToEntryPoint.Location = new System.Drawing.Point(19, 211);
|
||||
this.chkPassArgumentsToEntryPoint.Name = "chkPassArgumentsToEntryPoint";
|
||||
this.chkPassArgumentsToEntryPoint.Size = new System.Drawing.Size(119, 17);
|
||||
this.chkPassArgumentsToEntryPoint.TabIndex = 4;
|
||||
this.chkPassArgumentsToEntryPoint.Text = "Pass To Entry Point";
|
||||
this.chkPassArgumentsToEntryPoint.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// btnClearAllArguments
|
||||
//
|
||||
this.btnClearAllArguments.Location = new System.Drawing.Point(3, 181);
|
||||
this.btnClearAllArguments.Name = "btnClearAllArguments";
|
||||
this.btnClearAllArguments.Size = new System.Drawing.Size(145, 22);
|
||||
this.btnClearAllArguments.TabIndex = 3;
|
||||
this.btnClearAllArguments.Text = "Clear All";
|
||||
this.btnClearAllArguments.UseVisualStyleBackColor = true;
|
||||
this.btnClearAllArguments.Click += new System.EventHandler(this.btnClearAllArguments_Click);
|
||||
//
|
||||
// btnAddArgument
|
||||
//
|
||||
this.btnAddArgument.Location = new System.Drawing.Point(87, 154);
|
||||
this.btnAddArgument.Name = "btnAddArgument";
|
||||
this.btnAddArgument.Size = new System.Drawing.Size(61, 22);
|
||||
this.btnAddArgument.TabIndex = 2;
|
||||
this.btnAddArgument.Text = "Add";
|
||||
this.btnAddArgument.UseVisualStyleBackColor = true;
|
||||
this.btnAddArgument.Click += new System.EventHandler(this.btnAddArgument_Click);
|
||||
//
|
||||
// tbxArgument
|
||||
//
|
||||
this.tbxArgument.Location = new System.Drawing.Point(3, 155);
|
||||
this.tbxArgument.Name = "tbxArgument";
|
||||
this.tbxArgument.Size = new System.Drawing.Size(83, 20);
|
||||
this.tbxArgument.TabIndex = 1;
|
||||
//
|
||||
// lbxArguments
|
||||
//
|
||||
this.lbxArguments.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.lbxArguments.FormattingEnabled = true;
|
||||
this.lbxArguments.Location = new System.Drawing.Point(3, 16);
|
||||
this.lbxArguments.Name = "lbxArguments";
|
||||
this.lbxArguments.Size = new System.Drawing.Size(147, 134);
|
||||
this.lbxArguments.TabIndex = 0;
|
||||
//
|
||||
// AwkForm
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(649, 532);
|
||||
this.Controls.Add(this.tableLayoutPanel1);
|
||||
this.Controls.Add(this.panel2);
|
||||
this.Controls.Add(this.statusStrip1);
|
||||
this.Name = "AwkForm";
|
||||
this.Text = "ASE.COM.AWK";
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.panel1.ResumeLayout(false);
|
||||
this.panel1.PerformLayout();
|
||||
this.panel3.ResumeLayout(false);
|
||||
this.panel3.PerformLayout();
|
||||
this.panel4.ResumeLayout(false);
|
||||
this.panel4.PerformLayout();
|
||||
this.panel5.ResumeLayout(false);
|
||||
this.panel5.PerformLayout();
|
||||
this.panel2.ResumeLayout(false);
|
||||
this.panel2.PerformLayout();
|
||||
this.groupBox2.ResumeLayout(false);
|
||||
this.groupBox1.ResumeLayout(false);
|
||||
this.groupBox1.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.TextBox tbxSourceInput;
|
||||
private System.Windows.Forms.Button btnRun;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
private System.Windows.Forms.TextBox tbxSourceOutput;
|
||||
private System.Windows.Forms.TextBox tbxConsoleInput;
|
||||
private System.Windows.Forms.TextBox tbxConsoleOutput;
|
||||
private System.Windows.Forms.StatusStrip statusStrip1;
|
||||
private System.Windows.Forms.ComboBox cbxEntryPoint;
|
||||
private System.Windows.Forms.Panel panel2;
|
||||
private System.Windows.Forms.GroupBox groupBox1;
|
||||
private System.Windows.Forms.Button btnClearAllArguments;
|
||||
private System.Windows.Forms.Button btnAddArgument;
|
||||
private System.Windows.Forms.TextBox tbxArgument;
|
||||
private System.Windows.Forms.ListBox lbxArguments;
|
||||
private System.Windows.Forms.CheckBox chkPassArgumentsToEntryPoint;
|
||||
private System.Windows.Forms.GroupBox groupBox2;
|
||||
private System.Windows.Forms.Panel panel1;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Panel panel3;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.Panel panel4;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Panel panel5;
|
||||
private System.Windows.Forms.Label label4;
|
||||
}
|
||||
}
|
@ -1,87 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using System.IO;
|
||||
|
||||
namespace ase.com
|
||||
{
|
||||
public partial class AwkForm : Form
|
||||
{
|
||||
public AwkForm()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void btnRun_Click(object sender, EventArgs e)
|
||||
{
|
||||
Awk awk = new StdAwk ();
|
||||
|
||||
//System.Text.Encoding.Default
|
||||
awk.SourceInputStream = new MemoryStream (UnicodeEncoding.UTF8.GetBytes(tbxSourceInput.Text));
|
||||
awk.SourceOutputStream = new MemoryStream();
|
||||
|
||||
awk.ConsoleInputStream = new MemoryStream(UnicodeEncoding.UTF8.GetBytes(tbxConsoleInput.Text));
|
||||
awk.ConsoleOutputStream = new MemoryStream();
|
||||
|
||||
tbxSourceOutput.Text = "";
|
||||
tbxConsoleOutput.Text = "";
|
||||
|
||||
if (!awk.Parse())
|
||||
{
|
||||
MessageBox.Show(awk.ErrorMessage);
|
||||
}
|
||||
else
|
||||
{
|
||||
MemoryStream s = (MemoryStream)awk.SourceOutputStream;
|
||||
tbxSourceOutput.Text = UnicodeEncoding.UTF8.GetString(s.GetBuffer());
|
||||
|
||||
awk.EntryPoint = cbxEntryPoint.Text;
|
||||
awk.ArgumentsToEntryPoint = chkPassArgumentsToEntryPoint.Checked;
|
||||
|
||||
bool n;
|
||||
int nargs = lbxArguments.Items.Count;
|
||||
if (nargs > 0)
|
||||
{
|
||||
string[] args = new string[nargs];
|
||||
for (int i = 0; i < nargs; i++)
|
||||
args[i] = lbxArguments.Items[i].ToString();
|
||||
n = awk.Run(args);
|
||||
}
|
||||
else n = awk.Run();
|
||||
|
||||
if (!n)
|
||||
{
|
||||
MessageBox.Show(awk.ErrorMessage);
|
||||
}
|
||||
else
|
||||
{
|
||||
MemoryStream c = (MemoryStream)awk.ConsoleOutputStream;
|
||||
tbxConsoleOutput.Text = UnicodeEncoding.UTF8.GetString(c.GetBuffer());
|
||||
}
|
||||
}
|
||||
|
||||
//awk.Close();
|
||||
}
|
||||
|
||||
|
||||
private void btnAddArgument_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (tbxArgument.Text.Length > 0)
|
||||
{
|
||||
lbxArguments.Items.Add(tbxArgument.Text);
|
||||
tbxArgument.Text = "";
|
||||
tbxArgument.Focus();
|
||||
}
|
||||
}
|
||||
|
||||
private void btnClearAllArguments_Click(object sender, EventArgs e)
|
||||
{
|
||||
lbxArguments.Items.Clear();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
@ -1,123 +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=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>
|
||||
<metadata name="statusStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
</root>
|
@ -1,20 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace ase.com
|
||||
{
|
||||
static class Program
|
||||
{
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main()
|
||||
{
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
Application.Run(new AwkForm());
|
||||
}
|
||||
}
|
||||
}
|
@ -1,33 +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("ase.com")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("ase.com")]
|
||||
[assembly: AssemblyCopyright("© 2007 Hyung-Hwan Chung, All rights reserved.")]
|
||||
[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("7cd62543-7cf6-4b69-90b9-be0becdbfa19")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
63
ase/test/com/Properties/Resources.Designer.cs
generated
63
ase/test/com/Properties/Resources.Designer.cs
generated
@ -1,63 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:2.0.50727.42
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace ase.com.Properties {
|
||||
using System;
|
||||
|
||||
|
||||
/// <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", "2.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 (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ase.com.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>
|
26
ase/test/com/Properties/Settings.Designer.cs
generated
26
ase/test/com/Properties/Settings.Designer.cs
generated
@ -1,26 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:2.0.50727.42
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace ase.test.Properties {
|
||||
|
||||
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.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,60 +0,0 @@
|
||||
/*
|
||||
* $Id: StdAwk.cs,v 1.1 2007/09/03 03:50:39 bacon Exp $
|
||||
*/
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace ase.com
|
||||
{
|
||||
public class StdAwk: Awk
|
||||
{
|
||||
public StdAwk(): base ()
|
||||
{
|
||||
AddFunction("sin", 1, 1, new FunctionHandler(handleSin));
|
||||
AddFunction("cos", 1, 1, new FunctionHandler(handleCos));
|
||||
AddFunction("tan", 1, 1, new FunctionHandler(handleTan));
|
||||
}
|
||||
|
||||
protected virtual object handleSin(object[] args)
|
||||
{
|
||||
if (args[0] is System.Double)
|
||||
{
|
||||
return System.Math.Sin((double)args[0]);
|
||||
}
|
||||
else if (args[0] is System.Int32)
|
||||
{
|
||||
return System.Math.Sin((double)(int)args[0]);
|
||||
}
|
||||
else if (args[0] is System.Int64)
|
||||
{
|
||||
return System.Math.Sin((double)(long)args[0]);
|
||||
}
|
||||
else if (args[0] is string)
|
||||
{
|
||||
double t;
|
||||
|
||||
/* TODO: atoi */
|
||||
try { t = System.Double.Parse((string)args[0]); }
|
||||
catch (System.Exception e) { t = 0; }
|
||||
|
||||
return System.Math.Sin(t);
|
||||
}
|
||||
else
|
||||
{
|
||||
return System.Math.Sin(0.0);
|
||||
}
|
||||
}
|
||||
|
||||
protected virtual object handleCos(object[] args)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
protected virtual object handleTan(object[] args)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
@ -1,86 +0,0 @@
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.50727</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{F14B75D8-3ED7-4621-B5B9-E96A80B5D809}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>ase.com</RootNamespace>
|
||||
<AssemblyName>ase.com</AssemblyName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>..\..\Debug\bin\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<AllowUnsafeBlocks>false</AllowUnsafeBlocks>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>..\..\Release\bin\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Interop.ASECOM, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\cnt\obj\Debug\Interop.ASECOM.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<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="Awk.cs" />
|
||||
<Compile Include="AwkForm.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="AwkForm.Designer.cs">
|
||||
<DependentUpon>AwkForm.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="AwkForm.resx">
|
||||
<SubType>Designer</SubType>
|
||||
<DependentUpon>AwkForm.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>
|
||||
<DesignTime>True</DesignTime>
|
||||
</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>
|
||||
<Compile Include="StdAwk.cs" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\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,39 +0,0 @@
|
||||
Type=Exe
|
||||
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#..\..\..\..\..\WINDOWS\System32\stdole2.tlb#OLE Automation
|
||||
Reference=*\G{F9C69806-16A1-4162-998A-876B33C470BF}#1.0#0#..\..\debug\lib\asecom.dll#ASE 1.0 Type Library
|
||||
Form=AwkForm.frm
|
||||
Class=AwkExtioConsole; AwkExtioConsole.cls
|
||||
IconForm="AwkForm"
|
||||
Startup="AwkForm"
|
||||
HelpFile=""
|
||||
Title="ASECOM"
|
||||
ExeName32="asecom.exe"
|
||||
Command32=""
|
||||
Name="ASETESTCOM"
|
||||
HelpContextID="0"
|
||||
CompatibleMode="0"
|
||||
MajorVer=1
|
||||
MinorVer=0
|
||||
RevisionVer=0
|
||||
AutoIncrementVer=0
|
||||
ServerSupportFiles=0
|
||||
VersionProductName="ASE.COM"
|
||||
CompilationType=0
|
||||
OptimizationType=0
|
||||
FavorPentiumPro(tm)=0
|
||||
CodeViewDebugInfo=0
|
||||
NoAliasing=0
|
||||
BoundsCheck=0
|
||||
OverflowCheck=0
|
||||
FlPointCheck=0
|
||||
FDIVCheck=0
|
||||
UnroundedFP=0
|
||||
StartMode=0
|
||||
Unattended=0
|
||||
Retained=0
|
||||
ThreadPerObject=0
|
||||
MaxNumberOfThreads=1
|
||||
DebugStartupOption=0
|
||||
|
||||
[MS Transaction Server]
|
||||
AutoRefresh=1
|
@ -1,2 +0,0 @@
|
||||
AwkForm = 13, 12, 735, 661, , 22, 22, 753, 640, C
|
||||
AwkExtioConsole = 0, 0, 547, 460, C
|
@ -1,39 +0,0 @@
|
||||
Type=Exe
|
||||
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#..\..\..\..\WINDOWS\System32\stdole2.tlb#OLE Automation
|
||||
Reference=*\G{F9C69806-16A1-4162-998A-876B33C470BF}#1.0#0#..\..\Debug\lib\asecom.dll#ASE 1.0 Type Library
|
||||
Form=AwkForm.frm
|
||||
Class=AwkExtioConsole; AwkExtioConsole.cls
|
||||
IconForm="AwkForm"
|
||||
Startup="AwkForm"
|
||||
HelpFile=""
|
||||
Title="ASECOM"
|
||||
ExeName32="asecom.exe"
|
||||
Command32=""
|
||||
Name="ASETESTCOM"
|
||||
HelpContextID="0"
|
||||
CompatibleMode="0"
|
||||
MajorVer=1
|
||||
MinorVer=0
|
||||
RevisionVer=0
|
||||
AutoIncrementVer=0
|
||||
ServerSupportFiles=0
|
||||
VersionProductName="ASE.COM"
|
||||
CompilationType=0
|
||||
OptimizationType=0
|
||||
FavorPentiumPro(tm)=0
|
||||
CodeViewDebugInfo=0
|
||||
NoAliasing=0
|
||||
BoundsCheck=0
|
||||
OverflowCheck=0
|
||||
FlPointCheck=0
|
||||
FDIVCheck=0
|
||||
UnroundedFP=0
|
||||
StartMode=0
|
||||
Unattended=0
|
||||
Retained=0
|
||||
ThreadPerObject=0
|
||||
MaxNumberOfThreads=1
|
||||
DebugStartupOption=0
|
||||
|
||||
[MS Transaction Server]
|
||||
AutoRefresh=1
|
@ -1,2 +0,0 @@
|
||||
AwkForm = 13, 12, 735, 661, , 22, 22, 753, 640, C
|
||||
AwkExtioConsole = 0, 0, 547, 460, C
|
Reference in New Issue
Block a user