text:
namespace CJia.HIS.Clinic.Register.UI
{
    partial class RegisterView
    {
        /// <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 Component 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.btnSelectCardId = new DevExpress.XtraEditors.SimpleButton();
            this.gridControl1 = new DevExpress.XtraGrid.GridControl();
            this.gridView1 = new DevExpress.XtraGrid.Views.Grid.GridView();
            this.gridControl2 = new DevExpress.XtraGrid.GridControl();
            this.gridView2 = new DevExpress.XtraGrid.Views.Grid.GridView();
            this.lookUpEdit1 = new DevExpress.XtraEditors.LookUpEdit();
            panelControl6 = new DevExpress.XtraEditors.PanelControl();
            groupBox1 = new System.Windows.Forms.GroupBox();
            txtCardType = new DevExpress.XtraEditors.TextEdit();
            txtCardNO = new DevExpress.XtraEditors.TextEdit();
            labelControl2 = new DevExpress.XtraEditors.LabelControl();
            labelControl1 = new DevExpress.XtraEditors.LabelControl();
            panelControl7 = new DevExpress.XtraEditors.PanelControl();
            groupBox2 = new System.Windows.Forms.GroupBox();
            txtStatus = new DevExpress.XtraEditors.TextEdit();
            labelControl11 = new DevExpress.XtraEditors.LabelControl();
            txtPatientType = new DevExpress.XtraEditors.TextEdit();
            labelControl6 = new DevExpress.XtraEditors.LabelControl();
            txtIDCodeNO = new DevExpress.XtraEditors.TextEdit();
            labelControl7 = new DevExpress.XtraEditors.LabelControl();
            txtIDCodeType = new DevExpress.XtraEditors.TextEdit();
            labelControl8 = new DevExpress.XtraEditors.LabelControl();
            txtBirthday = new DevExpress.XtraEditors.TextEdit();
            labelControl5 = new DevExpress.XtraEditors.LabelControl();
            txtSex = new DevExpress.XtraEditors.TextEdit();
            labelControl4 = new DevExpress.XtraEditors.LabelControl();
            txtName = new DevExpress.XtraEditors.TextEdit();
            labelControl3 = new DevExpress.XtraEditors.LabelControl();
            panelControl9 = new DevExpress.XtraEditors.PanelControl();
            groupBox11 = new System.Windows.Forms.GroupBox();
            txtClinicType = new DevExpress.XtraEditors.TextEdit();
            btnReset = new DevExpress.XtraEditors.SimpleButton();
            btnEnter = new DevExpress.XtraEditors.SimpleButton();
            textEdit22 = new DevExpress.XtraEditors.TextEdit();
            labelControl38 = new DevExpress.XtraEditors.LabelControl();
            textEdit21 = new DevExpress.XtraEditors.TextEdit();
            labelControl37 = new DevExpress.XtraEditors.LabelControl();
            txtRegisterType = new DevExpress.XtraEditors.TextEdit();
            labelControl26 = new DevExpress.XtraEditors.LabelControl();
            labelControl10 = new DevExpress.XtraEditors.LabelControl();
            panelControl8 = new DevExpress.XtraEditors.PanelControl();
            groupBox5 = new System.Windows.Forms.GroupBox();
            panelControl1 = new DevExpress.XtraEditors.PanelControl();
            groupBox3 = new System.Windows.Forms.GroupBox();
            ((System.ComponentModel.ISupportInitialize)(this.gridControl1)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this.gridView1)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this.gridControl2)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(this.gridView2)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl6)).BeginInit();
            panelControl6.SuspendLayout();
            groupBox1.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(txtCardType.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtCardNO.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl7)).BeginInit();
            panelControl7.SuspendLayout();
            groupBox2.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(txtStatus.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtPatientType.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtIDCodeNO.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtIDCodeType.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtBirthday.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtSex.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtName.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl9)).BeginInit();
            panelControl9.SuspendLayout();
            groupBox11.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(txtClinicType.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(textEdit22.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(textEdit21.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(txtRegisterType.Properties)).BeginInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl8)).BeginInit();
            panelControl8.SuspendLayout();
            groupBox5.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(panelControl1)).BeginInit();
            panelControl1.SuspendLayout();
            groupBox3.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(this.lookUpEdit1.Properties)).BeginInit();
            this.SuspendLayout();
            //
            // btnSelectCardId
            //
            this.btnSelectCardId.Location = new System.Drawing.Point(135, 126);
            this.btnSelectCardId.Name = "btnSelectCardId";
            this.btnSelectCardId.Size = new System.Drawing.Size(75, 23);
            this.btnSelectCardId.TabIndex = 4;
            this.btnSelectCardId.Text = "²éѯ";
            this.btnSelectCardId.Click += new System.EventHandler(this.btnSelectCardId_Click);
            //
            // gridControl1
            //
            this.gridControl1.Dock = System.Windows.Forms.DockStyle.Fill;
            this.gridControl1.Location = new System.Drawing.Point(3, 18);
            this.gridControl1.MainView = this.gridView1;
            this.gridControl1.Name = "gridControl1";
            this.gridControl1.Size = new System.Drawing.Size(1019, 201);
            this.gridControl1.TabIndex = 25;
            this.gridControl1.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
            this.gridView1});
            //
            // gridView1
            //
            this.gridView1.GridControl = this.gridControl1;
            this.gridView1.Name = "gridView1";
            this.gridView1.OptionsView.ShowGroupPanel = false;
            //
            // gridControl2
            //
            this.gridControl2.Dock = System.Windows.Forms.DockStyle.Fill;
            this.gridControl2.Location = new System.Drawing.Point(3, 18);
            this.gridControl2.MainView = this.gridView2;
            this.gridControl2.Name = "gridControl2";
            this.gridControl2.Size = new System.Drawing.Size(461, 331);
            this.gridControl2.TabIndex = 26;
            this.gridControl2.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
            this.gridView2});
            //
            // gridView2
            //
            this.gridView2.GridControl = this.gridControl2;
            this.gridView2.Name = "gridView2";
            this.gridView2.OptionsView.ShowGroupPanel = false;
            //
            // panelControl6
            //
            panelControl6.Controls.Add(groupBox1);
            panelControl6.Location = new System.Drawing.Point(5, 5);
            panelControl6.Margin = new System.Windows.Forms.Padding(5);
            panelControl6.Name = "panelControl6";
            panelControl6.Size = new System.Drawing.Size(250, 162);
            panelControl6.TabIndex = 2;
            //
            // groupBox1
            //
            groupBox1.Controls.Add(txtCardType);
            groupBox1.Controls.Add(this.btnSelectCardId);
            groupBox1.Controls.Add(txtCardNO);
            groupBox1.Controls.Add(labelControl2);
            groupBox1.Controls.Add(labelControl1);
            groupBox1.Dock = System.Windows.Forms.DockStyle.Fill;
            groupBox1.Location = new System.Drawing.Point(2, 2);
            groupBox1.Name = "groupBox1";
            groupBox1.Size = new System.Drawing.Size(246, 158);
            groupBox1.TabIndex = 0;
            groupBox1.TabStop = false;
            groupBox1.Text = "²¡È˱àºÅ";
            //
            // txtCardType
            //
            txtCardType.Location = new System.Drawing.Point(75, 48);
            txtCardType.Name = "txtCardType";
            txtCardType.Size = new System.Drawing.Size(135, 20);
            txtCardType.TabIndex = 26;
            txtCardType.GotFocus += new System.EventHandler(this.txtCardType_GotFocus);
            //
            // txtCardNO
            //
            txtCardNO.Location = new System.Drawing.Point(75, 95);
            txtCardNO.Name = "txtCardNO";
            txtCardNO.Size = new System.Drawing.Size(135, 20);
            txtCardNO.TabIndex = 3;
            //
            // labelControl2
            //
            labelControl2.Location = new System.Drawing.Point(36, 74);
            labelControl2.Name = "labelControl2";
            labelControl2.Size = new System.Drawing.Size(60, 14);
            labelControl2.TabIndex = 2;
            labelControl2.Text = "¾ÍÕ│ºÅ£º";
            //
            // labelControl1
            //
            labelControl1.Location = new System.Drawing.Point(36, 25);
            labelControl1.Name = "labelControl1";
            labelControl1.Size = new System.Drawing.Size(72, 14);
            labelControl1.TabIndex = 0;
            labelControl1.Text = "¾ÍÕ│ÀàÐÍ£º";
            //
            // panelControl7
            //
            panelControl7.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
            | System.Windows.Forms.AnchorStyles.Left)));
            panelControl7.Controls.Add(groupBox2);
            panelControl7.Location = new System.Drawing.Point(5, 175);
            panelControl7.Name = "panelControl7";
            panelControl7.Size = new System.Drawing.Size(250, 420);
            panelControl7.TabIndex = 3;
            //
            // groupBox2
            //
            groupBox2.Controls.Add(txtStatus);
            groupBox2.Controls.Add(labelControl11);
            groupBox2.Controls.Add(txtPatientType);
            groupBox2.Controls.Add(labelControl6);
            groupBox2.Controls.Add(txtIDCodeNO);
            groupBox2.Controls.Add(labelControl7);
            groupBox2.Controls.Add(txtIDCodeType);
            groupBox2.Controls.Add(labelControl8);
            groupBox2.Controls.Add(txtBirthday);
            groupBox2.Controls.Add(labelControl5);
            groupBox2.Controls.Add(txtSex);
            groupBox2.Controls.Add(labelControl4);
            groupBox2.Controls.Add(txtName);
            groupBox2.Controls.Add(labelControl3);
            groupBox2.Dock = System.Windows.Forms.DockStyle.Fill;
            groupBox2.Location = new System.Drawing.Point(2, 2);
            groupBox2.Name = "groupBox2";
            groupBox2.Size = new System.Drawing.Size(246, 416);
            groupBox2.TabIndex = 0;
            groupBox2.TabStop = false;
            groupBox2.Text = "²¡È˵µ°¸";
            //
            // txtStatus
            //
            txtStatus.Location = new System.Drawing.Point(72, 364);
            txtStatus.Name = "txtStatus";
            txtStatus.Size = new System.Drawing.Size(135, 20);
            txtStatus.TabIndex = 17;
            //
            // labelControl11
            //
            labelControl11.Location = new System.Drawing.Point(33, 342);
            labelControl11.Name = "labelControl11";
            labelControl11.Size = new System.Drawing.Size(60, 14);
            labelControl11.TabIndex = 16;
            labelControl11.Text = "²¡ÈË״̬£º";
            //
            // txtPatientType
            //
            txtPatientType.Location = new System.Drawing.Point(72, 314);
            txtPatientType.Name = "txtPatientType";
            txtPatientType.Size = new System.Drawing.Size(135, 20);
            txtPatientType.TabIndex = 15;
            //
            // labelControl6
            //
            labelControl6.Location = new System.Drawing.Point(33, 292);
            labelControl6.Name = "labelControl6";
            labelControl6.Size = new System.Drawing.Size(60, 14);
            labelControl6.TabIndex = 14;
            labelControl6.Text = "²¡ÈËÀàÐÍ£º";
            //
            // txtIDCodeNO
            //
            txtIDCodeNO.Location = new System.Drawing.Point(72, 264);
            txtIDCodeNO.Name = "txtIDCodeNO";
            txtIDCodeNO.Size = new System.Drawing.Size(135, 20);
            txtIDCodeNO.TabIndex = 13;
            //
            // labelControl7
            //
            labelControl7.Location = new System.Drawing.Point(33, 242);
            labelControl7.Name = "labelControl7";
            labelControl7.Size = new System.Drawing.Size(48, 14);
            labelControl7.TabIndex = 12;
            labelControl7.Text = "Ö¤¼þºÅ£º";
            //
            // txtIDCodeType
            //
            txtIDCodeType.Location = new System.Drawing.Point(72, 214);
            txtIDCodeType.Name = "txtIDCodeType";
            txtIDCodeType.Size = new System.Drawing.Size(135, 20);
            txtIDCodeType.TabIndex = 11;
            //
            // labelControl8
            //
            labelControl8.Location = new System.Drawing.Point(33, 192);
            labelControl8.Name = "labelControl8";
            labelControl8.Size = new System.Drawing.Size(60, 14);
            labelControl8.TabIndex = 10;
            labelControl8.Text = "Ö¤¼þÀàÐÍ£º";
            //
            // txtBirthday
            //
            txtBirthday.Location = new System.Drawing.Point(72, 164);
            txtBirthday.Name = "txtBirthday";
            txtBirthday.Properties.Mask.BeepOnError = true;
            txtBirthday.Properties.Mask.EditMask = "D";
            txtBirthday.Properties.Mask.MaskType = DevExpress.XtraEditors.Mask.MaskType.DateTime;
            txtBirthday.Size = new System.Drawing.Size(135, 20);
            txtBirthday.TabIndex = 9;
            //
            // labelControl5
            //
            labelControl5.Location = new System.Drawing.Point(33, 142);
            labelControl5.Name = "labelControl5";
            labelControl5.Size = new System.Drawing.Size(60, 14);
            labelControl5.TabIndex = 8;
            labelControl5.Text = "³öÉúÈÕÆÚ£º";
            //
            // txtSex
            //
            txtSex.Location = new System.Drawing.Point(72, 114);
            txtSex.Name = "txtSex";
            txtSex.Size = new System.Drawing.Size(135, 20);
            txtSex.TabIndex = 7;
            //
            // labelControl4
            //
            labelControl4.Location = new System.Drawing.Point(33, 92);
            labelControl4.Name = "labelControl4";
            labelControl4.Size = new System.Drawing.Size(36, 14);
            labelControl4.TabIndex = 6;
            labelControl4.Text = "ÐÔ±ð£º";
            //
            // txtName
            //
            txtName.EditValue = "";
            txtName.Location = new System.Drawing.Point(72, 64);
            txtName.Name = "txtName";
            txtName.Properties.Mask.EditMask = "\\p{L}+";
            txtName.Size = new System.Drawing.Size(135, 20);
            txtName.TabIndex = 5;
            //
            // labelControl3
            //
            labelControl3.Location = new System.Drawing.Point(33, 42);
            labelControl3.Name = "labelControl3";
            labelControl3.Size = new System.Drawing.Size(36, 14);
            labelControl3.TabIndex = 4;
            labelControl3.Text = "ÐÕÃû£º";
            //
            // panelControl9
            //
            panelControl9.Controls.Add(groupBox11);
            panelControl9.Location = new System.Drawing.Point(263, 5);
            panelControl9.Name = "panelControl9";
            panelControl9.Size = new System.Drawing.Size(552, 356);
            panelControl9.TabIndex = 5;
            //
            // groupBox11
            //
            groupBox11.Controls.Add(this.lookUpEdit1);
            groupBox11.Controls.Add(txtClinicType);
            groupBox11.Controls.Add(btnReset);
            groupBox11.Controls.Add(btnEnter);
            groupBox11.Controls.Add(textEdit22);
            groupBox11.Controls.Add(labelControl38);
            groupBox11.Controls.Add(textEdit21);
            groupBox11.Controls.Add(labelControl37);
            groupBox11.Controls.Add(txtRegisterType);
            groupBox11.Controls.Add(labelControl26);
            groupBox11.Controls.Add(labelControl10);
            groupBox11.Dock = System.Windows.Forms.DockStyle.Fill;
            groupBox11.Location = new System.Drawing.Point(2, 2);
            groupBox11.Name = "groupBox11";
            groupBox11.Size = new System.Drawing.Size(548, 352);
            groupBox11.TabIndex = 0;
            groupBox11.TabStop = false;
            groupBox11.Text = "¹ÒºÅÐÅÏ¢";
            //
            // txtClinicType
            //
            txtClinicType.Location = new System.Drawing.Point(82, 61);
            txtClinicType.Name = "txtClinicType";
            txtClinicType.Size = new System.Drawing.Size(135, 20);
            txtClinicType.TabIndex = 26;
            //
            // btnReset
            //
            btnReset.Location = new System.Drawing.Point(142, 287);
            btnReset.Name = "btnReset";
            btnReset.Size = new System.Drawing.Size(75, 26);
            btnReset.TabIndex = 25;
            btnReset.Text = "ÖØÖÃ";
            //
            // btnEnter
            //
            btnEnter.Location = new System.Drawing.Point(409, 287);
            btnEnter.Name = "btnEnter";
            btnEnter.Size = new System.Drawing.Size(75, 26);
            btnEnter.TabIndex = 22;
            btnEnter.Text = "¹ÒºÅ";
            //
            // textEdit22
            //
            textEdit22.Location = new System.Drawing.Point(349, 209);
            textEdit22.Name = "textEdit22";
            textEdit22.Size = new System.Drawing.Size(135, 20);
            textEdit22.TabIndex = 13;
            //
            // labelControl38
            //
            labelControl38.Location = new System.Drawing.Point(310, 188);
            labelControl38.Name = "labelControl38";
            labelControl38.Size = new System.Drawing.Size(60, 14);
            labelControl38.TabIndex = 12;
            labelControl38.Text = "¹ÒºÅÒ½Éú£º";
            //
            // textEdit21
            //
            textEdit21.Location = new System.Drawing.Point(82, 206);
            textEdit21.Name = "textEdit21";
            textEdit21.Size = new System.Drawing.Size(135, 20);
            textEdit21.TabIndex = 11;
            //
            // labelControl37
            //
            labelControl37.Location = new System.Drawing.Point(43, 185);
            labelControl37.Name = "labelControl37";
            labelControl37.Size = new System.Drawing.Size(60, 14);
            labelControl37.TabIndex = 10;
            labelControl37.Text = "¹ÒºÅ¿ÆÊÒ£º";
            //
            // txtRegisterType
            //
            txtRegisterType.Location = new System.Drawing.Point(349, 61);
            txtRegisterType.Name = "txtRegisterType";
            txtRegisterType.Size = new System.Drawing.Size(135, 20);
            txtRegisterType.TabIndex = 9;
            //
            // labelControl26
            //
            labelControl26.Location = new System.Drawing.Point(310, 40);
            labelControl26.Name = "labelControl26";
            labelControl26.Size = new System.Drawing.Size(60, 14);
            labelControl26.TabIndex = 8;
            labelControl26.Text = "¹ÒºÅÀàÐÍ£º";
            //
            // labelControl10
            //
            labelControl10.Location = new System.Drawing.Point(43, 38);
            labelControl10.Name = "labelControl10";
            labelControl10.Size = new System.Drawing.Size(60, 14);
            labelControl10.TabIndex = 6;
            labelControl10.Text = "ÃÅÕïÀàÐÍ£º";
            //
            // panelControl8
            //
            panelControl8.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
            | System.Windows.Forms.AnchorStyles.Left)
            | System.Windows.Forms.AnchorStyles.Right)));
            panelControl8.Controls.Add(groupBox5);
            panelControl8.Location = new System.Drawing.Point(263, 369);
            panelControl8.Name = "panelControl8";
            panelControl8.Size = new System.Drawing.Size(1029, 226);
            panelControl8.TabIndex = 6;
            //
            // groupBox5
            //
            groupBox5.Controls.Add(this.gridControl1);
            groupBox5.Dock = System.Windows.Forms.DockStyle.Fill;
            groupBox5.Location = new System.Drawing.Point(2, 2);
            groupBox5.Name = "groupBox5";
            groupBox5.Size = new System.Drawing.Size(1025, 222);
            groupBox5.TabIndex = 0;
            groupBox5.TabStop = false;
            groupBox5.Text = "¹ÒºÅ¼Ç¼";
            //
            // panelControl1
            //
            panelControl1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
            | System.Windows.Forms.AnchorStyles.Right)));
            panelControl1.Controls.Add(groupBox3);
            panelControl1.Location = new System.Drawing.Point(821, 5);
            panelControl1.Name = "panelControl1";
            panelControl1.Size = new System.Drawing.Size(471, 356);
            panelControl1.TabIndex = 7;
            //
            // groupBox3
            //
            groupBox3.Controls.Add(this.gridControl2);
            groupBox3.Dock = System.Windows.Forms.DockStyle.Fill;
            groupBox3.Location = new System.Drawing.Point(2, 2);
            groupBox3.Name = "groupBox3";
            groupBox3.Size = new System.Drawing.Size(467, 352);
            groupBox3.TabIndex = 0;
            groupBox3.TabStop = false;
            groupBox3.Text = "·ÑÓÃÏêÇé";
            //
            // lookUpEdit1
            //
            this.lookUpEdit1.Location = new System.Drawing.Point(82, 114);
            this.lookUpEdit1.Name = "lookUpEdit1";
            this.lookUpEdit1.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
            new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
            this.lookUpEdit1.Size = new System.Drawing.Size(135, 20);
            this.lookUpEdit1.TabIndex = 27;
            //
            // RegisterView
            //
            this.Appearance.BackColor = System.Drawing.Color.White;
            this.Appearance.Options.UseBackColor = true;
            this.AutoSize = true;
            this.Controls.Add(panelControl1);
            this.Controls.Add(panelControl8);
            this.Controls.Add(panelControl9);
            this.Controls.Add(panelControl7);
            this.Controls.Add(panelControl6);
            this.Margin = new System.Windows.Forms.Padding(0);
            this.Name = "RegisterView";
            this.Size = new System.Drawing.Size(1300, 600);
            ((System.ComponentModel.ISupportInitialize)(this.gridControl1)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(this.gridView1)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(this.gridControl2)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(this.gridView2)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl6)).EndInit();
            panelControl6.ResumeLayout(false);
            groupBox1.ResumeLayout(false);
            groupBox1.PerformLayout();
            ((System.ComponentModel.ISupportInitialize)(txtCardType.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtCardNO.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl7)).EndInit();
            panelControl7.ResumeLayout(false);
            groupBox2.ResumeLayout(false);
            groupBox2.PerformLayout();
            ((System.ComponentModel.ISupportInitialize)(txtStatus.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtPatientType.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtIDCodeNO.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtIDCodeType.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtBirthday.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtSex.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtName.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl9)).EndInit();
            panelControl9.ResumeLayout(false);
            groupBox11.ResumeLayout(false);
            groupBox11.PerformLayout();
            ((System.ComponentModel.ISupportInitialize)(txtClinicType.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(textEdit22.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(textEdit21.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(txtRegisterType.Properties)).EndInit();
            ((System.ComponentModel.ISupportInitialize)(panelControl8)).EndInit();
            panelControl8.ResumeLayout(false);
            groupBox5.ResumeLayout(false);
            ((System.ComponentModel.ISupportInitialize)(panelControl1)).EndInit();
            panelControl1.ResumeLayout(false);
            groupBox3.ResumeLayout(false);
            ((System.ComponentModel.ISupportInitialize)(this.lookUpEdit1.Properties)).EndInit();
            this.ResumeLayout(false);

        }

        #endregion
        DevExpress.XtraEditors.PanelControl panelControl6;
        System.Windows.Forms.GroupBox groupBox1;
        DevExpress.XtraEditors.TextEdit txtCardType;
        DevExpress.XtraEditors.TextEdit txtCardNO;
        DevExpress.XtraEditors.LabelControl labelControl2;
        DevExpress.XtraEditors.LabelControl labelControl1;
        DevExpress.XtraEditors.PanelControl panelControl7;
        System.Windows.Forms.GroupBox groupBox2;
        DevExpress.XtraEditors.TextEdit txtStatus;
        DevExpress.XtraEditors.LabelControl labelControl11;
        DevExpress.XtraEditors.TextEdit txtPatientType;
        DevExpress.XtraEditors.LabelControl labelControl6;
        DevExpress.XtraEditors.TextEdit txtIDCodeNO;
        DevExpress.XtraEditors.LabelControl labelControl7;
        DevExpress.XtraEditors.TextEdit txtIDCodeType;
        DevExpress.XtraEditors.LabelControl labelControl8;
        DevExpress.XtraEditors.TextEdit txtBirthday;
        DevExpress.XtraEditors.LabelControl labelControl5;
        DevExpress.XtraEditors.TextEdit txtSex;
        DevExpress.XtraEditors.LabelControl labelControl4;
        DevExpress.XtraEditors.TextEdit txtName;
        DevExpress.XtraEditors.LabelControl labelControl3;
        DevExpress.XtraEditors.PanelControl panelControl9;
        System.Windows.Forms.GroupBox groupBox11;
        DevExpress.XtraEditors.TextEdit txtClinicType;
        DevExpress.XtraEditors.SimpleButton btnReset;
        DevExpress.XtraEditors.SimpleButton btnEnter;
        DevExpress.XtraEditors.TextEdit textEdit22;
        DevExpress.XtraEditors.LabelControl labelControl38;
        DevExpress.XtraEditors.TextEdit textEdit21;
        DevExpress.XtraEditors.LabelControl labelControl37;
        DevExpress.XtraEditors.TextEdit txtRegisterType;
        DevExpress.XtraEditors.LabelControl labelControl26;
        DevExpress.XtraEditors.LabelControl labelControl10;
        DevExpress.XtraEditors.PanelControl panelControl8;
        System.Windows.Forms.GroupBox groupBox5;
        DevExpress.XtraEditors.PanelControl panelControl1;
        System.Windows.Forms.GroupBox groupBox3;
        private DevExpress.XtraEditors.SimpleButton btnSelectCardId;
        private DevExpress.XtraGrid.GridControl gridControl1;
        private DevExpress.XtraGrid.Views.Grid.GridView gridView1;
        private DevExpress.XtraGrid.GridControl gridControl2;
        private DevExpress.XtraGrid.Views.Grid.GridView gridView2;
        private DevExpress.XtraEditors.LookUpEdit lookUpEdit1;

    }
}


text:
/*
 * vim:ts=4:sw=4:expandtab
 *
 * i3 - an improved dynamic tiling window manager
 * © 2009-2011 Michael Stapelberg and contributors (see also: LICENSE)
 *
 * yajl_utils.h
 *
 */
#pragma once

#include <yajl/yajl_gen.h>
#include <yajl/yajl_parse.h>
#include <yajl/yajl_version.h>

/* Shorter names for all those yajl_gen_* functions */
#define y(x, ...) yajl_gen_ ## x (gen, ##__VA_ARGS__)
#define ystr(str) yajl_gen_string(gen, (unsigned char*)str, strlen(str))

#if YAJL_MAJOR >= 2
#define ygenalloc() yajl_gen_alloc(NULL)
#define yalloc(callbacks, client) yajl_alloc(callbacks, NULL, client)
typedef size_t ylength;
#else
#define ygenalloc() yajl_gen_alloc(NULL, NULL);
#define yalloc(callbacks, client) yajl_alloc(callbacks, NULL, NULL, client)
typedef unsigned int ylength;
#endif

redpajama_set_name: RedPajamaGithub


text:
package org.sakaiproject.importer.impl;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

import javax.xml.XMLConstants;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;

import org.sakaiproject.archive.api.ImportMetadata;
import org.sakaiproject.archive.cover.ImportMetadataService;
import org.sakaiproject.importer.api.ImportDataSource;
import org.sakaiproject.importer.api.ImportFileParser;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import org.xml.sax.SAXException;

public class SakaiArchiveFileParser extends ZipFileParser {

	private static final String LEGACY_TOOL = "legacyTool";
	private static final String SAKAI_TOOL = "sakaiTool";
	private static final String ROOT = "importConfiguration";
	private static final String MAPPINGS = "mappings";
	private static final String MAP = "map";
	private static final String SERVICE_NAME = "serviceName";
	private static final String FILE_NAME = "filename";
	private static final String MANDATORY = "mandatory";
	private static final String ID = "id";

	protected Document importMappings;

	public boolean isValidArchive(InputStream fileData) {
		if (super.isValidArchive(fileData)) {
			if (!fileExistsInArchive("/import_mappings.xml", fileData))
				return false;
			return true;
		} else return false;
	}

	protected void awakeFromUnzip(String unArchiveLocation) {
		this.pathToData = unArchiveLocation;
		String absolutepathToManifest = pathToData + "/" + "import_mappings.xml";
	    absolutepathToManifest = absolutepathToManifest.replace('\\', '/');
        InputStream fis = null;
        try {
            fis = new FileInputStream(absolutepathToManifest);
            DocumentBuilderFactory builderFactory = DocumentBuilderFactory.newInstance();
            builderFactory.setFeature(XMLConstants.FEATURE_SECURE_PROCESSING, true);
            builderFactory.setFeature("http://xml.org/sax/features/external-general-entities", false);
            builderFactory.setFeature("http://xml.org/sax/features/external-parameter-entities", false);
            DocumentBuilder docBuilder = builderFactory.newDocumentBuilder();
            this.importMappings = (Document) docBuilder.parse(fis);
        } catch (FileNotFoundException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (ParserConfigurationException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (SAXException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } finally {
            if (fis != null) {
                try {
                    fis.close();
                } catch (IOException e) {
                    // TODO Auto-generated catch block
                    e.printStackTrace();
                }
            }
        }

	}

	public ImportFileParser newParser() {
		return new SakaiArchiveFileParser();
	}

	public ImportDataSource parse(InputStream fileData, String unArchiveLocation) {
		this.localArchiveLocation = unzipArchive(fileData, unArchiveLocation);
		this.pathToData = unArchiveLocation + "/" + localArchiveLocation;
		awakeFromUnzip(pathToData);
		List categories = new ArrayList();
		Collection items = new ArrayList();
		categories.addAll(getCategoriesFromArchive(pathToData));
		items.addAll(getImportableItemsFromArchive(pathToData));

		SakaiArchiveDataSource dataSource = new SakaiArchiveDataSource(fileData, localArchiveLocation, pathToData);
	    dataSource.setItemCategories(categories);
	    dataSource.setItems(items);
	    return dataSource;
	}

	protected Collection getCategoriesFromArchive(String pathToData) {
		return ImportMetadataService.getImportMetadataElements(importMappings);
	}

	protected Collection getImportableItemsFromArchive(String pathToData) {
		return new ArrayList();
	}

//	public List getImportMetadataElements(Document doc)
//	  {
//	    if (doc == null)
//	    {
//	      throw new IllegalArgumentException("Illegal document argument!");
//	    }
//	    else
//	    {
//	      //TODO: Validate the Doc against DTD
//	      Element root = doc.getDocumentElement();
//	      if (root.getTagName().equals(ROOT))
//	      {
//	        NodeList rootNodeList = root.getChildNodes();
//	        final int length = rootNodeList.getLength();
//	        for (int i = 0; i < length; i++)
//	        {
//	          Node mapping = rootNodeList.item(i);
//	          if (mapping.getNodeType() != Node.ELEMENT_NODE)
//	          {
//	            continue;
//	          }
//	          Element mappingElement = (Element) mapping;
//	          if (mappingElement.getTagName().equals(MAPPINGS))
//	          {
//	            List maps = new ArrayList();
//	            NodeList mapNode = mappingElement.getChildNodes();
//	            final int mapLength = mapNode.getLength();
//	            for (int j = 0; j < mapLength; j++)
//	            {
//	              Node mapNodes = mapNode.item(j);
//	              if (mapNodes.getNodeType() != Node.ELEMENT_NODE)
//	              {
//	                continue;
//	              }
//	              Element mapElement = (Element) mapNodes;
//	              if (mapElement.getTagName().equals(MAP))
//	              {
//	                ImportMetadataImpl importMetadataMap = new ImportMetadataImpl();
//	                importMetadataMap.setId(mapElement.getAttribute(ID));
//	                importMetadataMap.setFileName(mapElement
//	                    .getAttribute(FILE_NAME));
//	                importMetadataMap.setLegacyTool(mapElement
//	                    .getAttribute(LEGACY_TOOL));
//
//	                importMetadataMap.setSakaiTool(mapElement
//	                    .getAttribute(SAKAI_TOOL));
//	                importMetadataMap.setSakaiServiceName(mapElement
//	                    .getAttribute(SERVICE_NAME));
//	                if (mapElement.getAttribute(MANDATORY) != null
//	                    && mapElement.getAttribute(MANDATORY).length() > 0
//	                    && mapElement.getAttribute(MANDATORY).endsWith("true"))
//	                {
//	                  importMetadataMap.setMandatory(true);
//	                }
//	                maps.add(importMetadataMap);
//	              }
//	            }
//	            // import_mapping shall contain only one mapping element, after the
//	            // first one is done return
//	            return maps;
//	          }
//	        }
//	      }
//	    }
//
//	    return null;
//	  }

//	    public class ImportMetadataImpl implements ImportMetadata
//	    {
//
//	      private String id;
//	      private String legacyTool;
//	      private String sakaiTool;
//	      private String sakaiServiceName;
//	      private String fileName;
//	      private boolean mandatory = false;
//
//	      /**
//	       * Should only be constructed by ImportMetadataService.
//	       */
//	      ImportMetadataImpl()
//	      {
//	      }
//
//	      /**
//	       * @return Returns the id.
//	       */
//	      public String getId()
//	      {
//	        return id;
//	      }
//
//	      /**
//	       * @param id
//	       *          The id to set.
//	       */
//	      public void setId(String id)
//	      {
//	        this.id = id;
//	      }
//
//	      /**
//	       * @return Returns the fileName.
//	       */
//	      public String getFileName()
//	      {
//	        return fileName;
//	      }
//
//	      /**
//	       * @param fileName
//	       *          The fileName to set.
//	       */
//	      public void setFileName(String fileName)
//	      {
//	        this.fileName = fileName;
//	      }
//
//	      /**
//	       * @return Returns the legacyTool.
//	       */
//	      public String getLegacyTool()
//	      {
//	        return legacyTool;
//	      }
//
//	      /**
//	       * @param legacyTool
//	       *          The legacyTool to set.
//	       */
//	      public void setLegacyTool(String legacyTool)
//	      {
//	        this.legacyTool = legacyTool;
//	      }
//
//	      /**
//	       * @return Returns the mandatory.
//	       */
//	      public boolean isMandatory()
//	      {
//	        return mandatory;
//	      }
//
//	      /**
//	       * @param mandatory
//	       *          The mandatory to set.
//	       */
//	      public void setMandatory(boolean mandatory)
//	      {
//	        this.mandatory = mandatory;
//	      }
//
//	      /**
//	       * @return Returns the sakaiServiceName.
//	       */
//	      public String getSakaiServiceName()
//	      {
//	        return sakaiServiceName;
//	      }
//
//	      /**
//	       * @param sakaiServiceName
//	       *          The sakaiServiceName to set.
//	       */
//	      public void setSakaiServiceName(String sakaiServiceName)
//	      {
//	        this.sakaiServiceName = sakaiServiceName;
//	      }
//
//	      /**
//	       * @return Returns the sakaiTool.
//	       */
//	      public String getSakaiTool()
//	      {
//	        return sakaiTool;
//	      }
//
//	      /**
//	       * @param sakaiTool
//	       *          The sakaiTool to set.
//	       */
//	      public void setSakaiTool(String sakaiTool)
//	      {
//	        this.sakaiTool = sakaiTool;
//	      }
//
//	    }
}


text:
package io.pebbletemplates.pebble.attributes;

import io.pebbletemplates.pebble.error.AttributeNotFoundException;
import io.pebbletemplates.pebble.node.ArgumentsNode;
import io.pebbletemplates.pebble.template.EvaluationContextImpl;

import java.lang.reflect.Array;

class ArrayResolver implements AttributeResolver {

  static final ArrayResolver INSTANCE = new ArrayResolver();

  private ArrayResolver() {
  }

  @Override
  public ResolvedAttribute resolve(Object instance,
      Object attributeNameValue,
      Object[] argumentValues,
      ArgumentsNode args,
      EvaluationContextImpl context,
      String filename,
      int lineNumber) {
    String attributeName = String.valueOf(attributeNameValue);
    int index = this.getIndex(attributeName);
    int length = Array.getLength(instance);
    if (index < 0 || index >= length) {
      if (context.isStrictVariables()) {
        throw new AttributeNotFoundException(null,
            "Index out of bounds while accessing array with strict variables on.",
            attributeName, lineNumber, filename);
      } else {
        return new ResolvedAttribute(null);
      }
    }
    return new ResolvedAttribute(Array.get(instance, index));
  }

  private int getIndex(String attributeName) {
    try {
      return Integer.parseInt(attributeName);
    } catch (NumberFormatException e) {
      return -1;
    }
  }
}


text:
struct AbstractInPlaceTypeFunctions
{
    virtual ~AbstractInPlaceTypeFunctions();
    virtual void construct(void * place) const=0;
    virtual void destruct(void * place) const=0;
    virtual void copyTo(const void * from, void * to) const=0;
    // virtual void moveTo(void * from, void * to) const=0;
};

template <typename T>
struct InPlaceTypeFunctions : public AbstractInPlaceTypeFunctions
{
    void construct(void * place) const
    {
        new(place) T;
    }
    void destruct(void * place) const
    {
        static_cast<T*>(place)->~T();
    }
    void copyTo(const void * from, void * to) const
    {
        new(to) T(static_cast <const T&>(*from));
    }
};

class QtTypeFunctions : public AbstractInPlaceTypeFunctions
{
public:
    QtTypeFunctions(const char * qTypeName);

    void construct(void * place) const;
    void destruct(void * place) const;
    void copyTo(const void * from, void * to) const;

protected:
    int m_typeId;
};


text:
@implementation AnalyticsKitFlurryProvider

-(id<AnalyticsKitProvider>)initWithAPIKey:(NSString *)apiKey {
    self = [super init];
    if (self) {
        [Flurry startSession:apiKey];
    }
    return self;
}

-(void)runInMainThread:(void (^)(void))block{
    //Flurry requires calls to be made from main thread
    if ([NSThread isMainThread]){
        block();
    } else {
        dispatch_async(dispatch_get_main_queue(), ^{
            block();
        });
    }
}

-(void)applicationWillEnterForeground {}
-(void)applicationDidEnterBackground {}
-(void)applicationWillTerminate {}

-(void)uncaughtException:(NSException *)exception {
    NSString *message = [NSString stringWithFormat:@"Crash on iOS %@", [[UIDevice currentDevice] systemVersion]];
    [Flurry logError:@"Uncaught" message:message exception:exception];
}

-(void)logScreen:(NSString *)screenName {
    [self runInMainThread:^{
        [Flurry logEvent:[@"Screen - " stringByAppendingString:screenName]];
    }];
}

-(void)logEvent:(NSString *)value {
    [self runInMainThread:^{
        [Flurry logEvent:value];
    }];
}

-(void)logEvent:(NSString *)event withProperties:(NSDictionary *)dict {
    [self runInMainThread:^{
        [Flurry logEvent:event withParameters:dict];
    }];
}

-(void)logEvent:(NSString *)event withProperty:(NSString *)key andValue:(NSString *)value {
    [self runInMainThread:^{
        [Flurry logEvent:event withParameters:[NSDictionary dictionaryWithObject:value forKey:key]];
    }];
}

- (void)logEvent:(NSString *)eventName timed:(BOOL)timed{
    [self runInMainThread:^{
        [Flurry logEvent:eventName timed:timed];
    }];
}

- (void)logEvent:(NSString *)eventName withProperties:(NSDictionary *)dict timed:(BOOL)timed{
    [self runInMainThread:^{
        [Flurry logEvent:eventName withParameters:dict timed:timed];

    }];
}

-(void)endTimedEvent:(NSString *)eventName withProperties:(NSDictionary *)dict{
    [self runInMainThread:^{
        // non-nil parameters will update the parameters
        [Flurry endTimedEvent:eventName withParameters:dict];
     }];
}

-(void)logError:(NSString *)name message:(NSString *)message exception:(NSException *)exception {
    [self runInMainThread:^{
        [Flurry logError:name message:message exception:exception];
    }];
}

-(void)logError:(NSString *)name message:(NSString *)message error:(NSError *)error {
    [self runInMainThread:^{
        [Flurry logError:name message:message error:error];
    }];
}

@end


text:
using System;
namespace aaLogReader
{
    interface ILogHeader
    {
        string LogFilePath { get; set; }
        string ComputerName { get; set; }
        ulong EndFileTime { get; set; }
        DateTimeOffset EndDateTime { get; }
        DateTime EndDateTimeLocal { get; }
        DateTime EndDateTimeUtc { get; }
        string HostFQDN { get; set; }
        ulong MsgCount { get; set; }
        ulong EndMsgNumber { get; }
        ulong StartMsgNumber { get; set; }
        int OffsetFirstRecord { get; set; }
        int OffsetLastRecord { get; set; }
        string PrevFileName { get; set; }
        ReturnCodeStruct ReturnCode { get; set; }
        string Session { get; set; }
        ulong StartFileTime { get; set; }
        DateTimeOffset StartDateTime { get; }
        DateTime StartDateTimeLocal { get; }
        DateTime StartDateTimeUtc { get; }
        string ToCSV();
        string ToDelimitedString(char Delimiter = ',');
        string ToJSON();
        string ToKVP();
        string ToTSV();
    }
}


text:
package org.mybatis.guice.sample.service;

import javax.inject.Inject;

import org.mybatis.guice.CustomException;
import org.mybatis.guice.sample.dao.UserDao;
import org.mybatis.guice.sample.domain.User;
import org.mybatis.guice.transactional.Isolation;
import org.mybatis.guice.transactional.Transactional;

/**
 * Impl of the FooService.
 * <p>
 * FooService simply receives a userId and uses a mapper/dao to get a record from the database.
 */
@Transactional(rethrowExceptionsAs = CustomException.class)
public class FooServiceDaoImpl implements FooService {

  private UserDao userDao;

  @Inject
  public void setUserDao(UserDao userDao) {
    this.userDao = userDao;
  }

  @Override
  @Transactional(isolation = Isolation.SERIALIZABLE)
  public User doSomeBusinessStuff(String userId) {
    return this.userDao.getUser(userId);
  }

  @Override
  @Transactional(isolation = Isolation.SERIALIZABLE, rethrowExceptionsAs = IllegalArgumentException.class)
  public void brokenInsert(User user) {
    this.userDao.brokenInsert(user);
  }

  @Override
  public void brokenInsert2(User user) {
    this.userDao.brokenInsert(user);
  }
}


text:
/* Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.activiti.engine.impl.scripting;

import java.util.Arrays;
import java.util.Collection;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;

import javax.script.Bindings;

import org.activiti.engine.delegate.VariableScope;

/**
 * @author Tom Baeyens
 */
public class ScriptBindings implements Bindings {

  /**
   * The script engine implementations put some key/value pairs into the binding.
   * This list contains those keys, such that they wouldn't be stored as process variable.
   *
   * This list contains the keywords for JUEL, Javascript and Groovy.
   */
  protected static final Set<String> UNSTORED_KEYS =
    new HashSet<String>(Arrays.asList("out", "out:print", "lang:import", "context", "elcontext", "print", "println"));

  protected List<Resolver> scriptResolvers;
  protected VariableScope variableScope;

  public ScriptBindings(List<Resolver> scriptResolvers, VariableScope variableScope) {
    this.scriptResolvers = scriptResolvers;
    this.variableScope = variableScope;
  }

  public boolean containsKey(Object key) {
    for (Resolver scriptResolver: scriptResolvers) {
      if (scriptResolver.containsKey(key)) {
        return true;
      }
    }
    return false;
  }

  public Object get(Object key) {
    for (Resolver scriptResolver: scriptResolvers) {
      if (scriptResolver.containsKey(key)) {
        return scriptResolver.get(key);
      }
    }
    return null;
  }

  public Object put(String name, Object value) {
    Object oldValue = null;
    if (!UNSTORED_KEYS.contains(name)) {
      oldValue = variableScope.getVariable(name);
      variableScope.setVariable(name, value);
    }
    return oldValue;
  }

  public Set<java.util.Map.Entry<String, Object>> entrySet() {
    throw new UnsupportedOperationException();
//    return variableScope.getVariables().entrySet();
  }

  public Set<String> keySet() {
    throw new UnsupportedOperationException();
//    return variableScope.getVariables().keySet();
  }

  public int size() {
    throw new UnsupportedOperationException();
//    return variableScope.getVariables().size();
  }

  public Collection<Object> values() {
    throw new UnsupportedOperationException();
//    return variableScope.getVariables().values();
  }

  public void putAll(Map< ? extends String, ? extends Object> toMerge) {
    throw new UnsupportedOperationException();
  }

  public Object remove(Object key) {
    if (UNSTORED_KEYS.contains(key)) {
      return null;
    }
    throw new UnsupportedOperationException();
  }

  public void clear() {
    throw new UnsupportedOperationException();
  }

  public boolean containsValue(Object value) {
    throw new UnsupportedOperationException();
  }

  public boolean isEmpty() {
    throw new UnsupportedOperationException();
  }

}


text:
package com.groupon.odo.controllers;

import com.groupon.odo.proxylib.ConfigurationService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.servlet.handler.HandlerInterceptorAdapter;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/*
 * This interceptor checks to make sure that all configuration properties were handled
 * If they were not then it redirects to the Proxy configuration controller
 */
public class ConfigurationInterceptor extends HandlerInterceptorAdapter {
    private static final Logger logger = LoggerFactory
            .getLogger(ConfigurationInterceptor.class);

    /**
     * This will check to see if certain configuration values exist from the ConfigurationService
     * If not then it redirects to the configuration screen
     */
    public boolean preHandle(HttpServletRequest request,
                             HttpServletResponse response, Object handler) throws Exception {

        String queryString = request.getQueryString() == null ? "" : request.getQueryString();

        if (ConfigurationService.getInstance().isValid()
                || request.getServletPath().startsWith("/configuration")
                || request.getServletPath().startsWith("/resources")
                || queryString.contains("requestFromConfiguration=true")) {
            return true;
        } else {
            response.sendRedirect("configuration");
            return false;
        }
    }
}


text:
var expect = require('expect.js');
var sinon = require('sinon');
var mockery = require('mockery');

describe('reject', function () {
    var executeCredential;
    var repo;
    var libPath = '../../lib/commands/reject';
    var reject;

    beforeEach(function () {
        executeCredential = sinon.stub();
        repo = sinon.stub();

        mockery.enable({
            useCleanCache: true,
            warnOnUnregistered: false
        });

        mockery.registerMock('../util/executeCredential', executeCredential);
        mockery.registerMock('../util/repo', repo);
        mockery.registerAllowable(libPath, true);
        reject = require(libPath);
    });

    afterEach(function() {
        mockery.deregisterAll();
        mockery.resetCache();
        mockery.disable();
    });

    it('should return nothing when the tool has accepted the rejection', function (done) {
        var testServer = { mock: 'foo'};
        var testTarget = 'http://foo.not.found';
        executeCredential.yields(null, {});
        repo.returns(testServer);

        reject(testTarget, function(err, data) {
            expect(data).to.eql({});

            expect(executeCredential.called).to.be(true);
            expect(executeCredential.args[0][0]).to.eql(['reject']);
            expect(executeCredential.args[0][2]).to.eql(testServer);

            expect(repo.called).to.be(true);
            expect(repo.args[0][0]).to.be(testTarget);

            done();
        });
    });
});


text:
package injectexec

import (
	"fmt"
	"testing"

	"github.com/heketi/tests"

	"github.com/heketi/heketi/executors/cmdexec"
	"github.com/heketi/heketi/executors/mockexec"
)

func TestBasicWrapping(t *testing.T) {
	me, err := mockexec.NewMockExecutor()
	tests.Assert(t, err == nil, "expected err == nil, got:", err)

	ie := NewInjectExecutor(me, &InjectConfig{})
	tests.Assert(t, ie != nil, "expected ie != nil, got:", ie)

	err = ie.PeerProbe("foo", "target")
	tests.Assert(t, err == nil, "expected err == nil, got:", err)

	me.MockPeerProbe = func(host, newnode string) error {
		tests.Assert(t, host == "foo", "expected host == foo, got:", host)
		return fmt.Errorf("FAKE")
	}

	err = ie.PeerProbe("foo", "target")
	tests.Assert(t, err.Error() == "FAKE", "expected err == FAKE, got:", err)

	// now test override behavior
	ie.Pre.MockPeerProbe = func(host, newnode string) error {
		return fmt.Errorf("FOOBAR")
	}
	err = ie.PeerProbe("foo", "target")
	tests.Assert(t, err.Error() == "FOOBAR", "expected err == FOOBAR, got:", err)
}

func newDummyExecutor() *cmdexec.CmdExecutor {
	d := &cmdexec.CmdExecutor{}
	d.RemoteExecutor = &DummyTransport{}
	d.Init(&cmdexec.CmdConfig{})
	return d
}

func TestCmdexecWrapping(t *testing.T) {
	ic := &InjectConfig{}
	de := newDummyExecutor()
	ie := NewInjectExecutor(de, ic)
	tests.Assert(t, ie != nil, "expected ie != nil, got:", ie)

	err := ie.PeerProbe("foo", "target")
	tests.Assert(t, err == nil, "expected err == nil, got:", err)
}

func TestCmdexecWrapCommand(t *testing.T) {
	ic := &InjectConfig{}
	ic.CmdInjection.CmdHooks = CmdHooks{
		CmdHook{
			Cmd:      ".*",
			Reaction: Reaction{Err: "BLAMMO"},
		},
	}
	de := newDummyExecutor()
	ie := NewInjectExecutor(de, ic)
	tests.Assert(t, ie != nil, "expected ie != nil, got:", ie)

	err := ie.PeerProbe("foo", "target")
	tests.Assert(t, err != nil, "expected err == nil, got:", err)
	tests.Assert(t, err.Error() == "BLAMMO", "expected err == BLAMMO, got:", err)
}

func TestCmdexecWrapResult(t *testing.T) {
	ic := &InjectConfig{}
	ic.CmdInjection.ResultHooks = ResultHooks{
		ResultHook{
			Result: ".*",
			CmdHook: CmdHook{
				Cmd:      ".*",
				Reaction: Reaction{Err: "BLAMMO"},
			},
		},
	}
	de := newDummyExecutor()
	ie := NewInjectExecutor(de, ic)
	tests.Assert(t, ie != nil, "expected ie != nil, got:", ie)

	err := ie.PeerProbe("foo", "target")
	tests.Assert(t, err != nil, "expected err == nil, got:", err)
	tests.Assert(t, err.Error() == "BLAMMO", "expected err == BLAMMO, got:", err)
}


text:
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>org.jbpm</groupId>
    <artifactId>jbpm-container-integration-deps</artifactId>
    <version>7.58.0-SNAPSHOT</version>
  </parent>

  <artifactId>idep-rest</artifactId>

  <name>jBPM :: Container Test IDEPS REST</name>

  <dependencies>
    <dependency>
      <groupId>org.jboss.resteasy</groupId>
      <artifactId>resteasy-jaxrs</artifactId>
      <exclusions>
        <exclusion>
          <groupId>commons-logging</groupId>
          <artifactId>commons-logging</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <!-- Replacement for above excluded 'commons-logging:commons-logging' -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>jcl-over-slf4j</artifactId>
      <scope>runtime</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.resteasy</groupId>
      <artifactId>resteasy-jackson-provider</artifactId>
    </dependency>
  </dependencies>

</project>


text:
std::string DATA_PATH = "../../../data/";
#else
std::string DATA_PATH = "../../data/";
#endif

namespace yarrar
{
namespace io
{

void readFile(const std::string& relativePath, std::string& toBuffer)
{
    std::ifstream file;
    file.open(DATA_PATH + relativePath, std::ios::in | std::ios::binary);
    if(!file.is_open())
    {
        throw std::runtime_error(std::string("failed to open file: ") + relativePath);
    }

    std::stringstream buffer;
    buffer << file.rdbuf();
    toBuffer = buffer.str();
}
}
}


text:
    void alphaFunc(AlphaTestFunc funcPacked, GLfloat ref);                                       \
    void alphaFuncx(AlphaTestFunc funcPacked, GLfixed ref);                                      \
    void clearColorx(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);                   \
    void clearDepthx(GLfixed depth);                                                             \
    void clientActiveTexture(GLenum texture);                                                    \
    void clipPlanef(GLenum p, const GLfloat *eqn);                                               \
    void clipPlanex(GLenum plane, const GLfixed *equation);                                      \
    void color4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);                       \
    void color4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);                      \
    void color4x(GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);                       \
    void colorPointer(GLint size, VertexAttribType typePacked, GLsizei stride,                   \
                      const void *pointer);                                                      \
    void depthRangex(GLfixed n, GLfixed f);                                                      \
    void disableClientState(ClientVertexArrayType arrayPacked);                                  \
    void enableClientState(ClientVertexArrayType arrayPacked);                                   \
    void fogf(GLenum pname, GLfloat param);                                                      \
    void fogfv(GLenum pname, const GLfloat *params);                                             \
    void fogx(GLenum pname, GLfixed param);                                                      \
    void fogxv(GLenum pname, const GLfixed *param);                                              \
    void frustumf(GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f);             \
    void frustumx(GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);             \
    void getClipPlanef(GLenum plane, GLfloat *equation);                                         \
    void getClipPlanex(GLenum plane, GLfixed *equation);                                         \
    void getFixedv(GLenum pname, GLfixed *params);                                               \
    void getLightfv(GLenum light, LightParameter pnamePacked, GLfloat *params);                  \
    void getLightxv(GLenum light, LightParameter pnamePacked, GLfixed *params);                  \
    void getMaterialfv(GLenum face, MaterialParameter pnamePacked, GLfloat *params);             \
    void getMaterialxv(GLenum face, MaterialParameter pnamePacked, GLfixed *params);             \
    void getTexEnvfv(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked,             \
                     GLfloat *params);                                                           \
    void getTexEnviv(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked,             \
                     GLint *params);                                                             \
    void getTexEnvxv(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked,             \
                     GLfixed *params);                                                           \
    void getTexParameterxv(TextureType targetPacked, GLenum pname, GLfixed *params);             \
    void lightModelf(GLenum pname, GLfloat param);                                               \
    void lightModelfv(GLenum pname, const GLfloat *params);                                      \
    void lightModelx(GLenum pname, GLfixed param);                                               \
    void lightModelxv(GLenum pname, const GLfixed *param);                                       \
    void lightf(GLenum light, LightParameter pnamePacked, GLfloat param);                        \
    void lightfv(GLenum light, LightParameter pnamePacked, const GLfloat *params);               \
    void lightx(GLenum light, LightParameter pnamePacked, GLfixed param);                        \
    void lightxv(GLenum light, LightParameter pnamePacked, const GLfixed *params);               \
    void lineWidthx(GLfixed width);                                                              \
    void loadIdentity();                                                                         \
    void loadMatrixf(const GLfloat *m);                                                          \
    void loadMatrixx(const GLfixed *m);                                                          \
    void logicOp(LogicalOperation opcodePacked);                                                 \
    void materialf(GLenum face, MaterialParameter pnamePacked, GLfloat param);                   \
    void materialfv(GLenum face, MaterialParameter pnamePacked, const GLfloat *params);          \
    void materialx(GLenum face, MaterialParameter pnamePacked, GLfixed param);                   \
    void materialxv(GLenum face, MaterialParameter pnamePacked, const GLfixed *param);           \
    void matrixMode(MatrixType modePacked);                                                      \
    void multMatrixf(const GLfloat *m);                                                          \
    void multMatrixx(const GLfixed *m);                                                          \
    void multiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);             \
    void multiTexCoord4x(GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q);            \
    void normal3f(GLfloat nx, GLfloat ny, GLfloat nz);                                           \
    void normal3x(GLfixed nx, GLfixed ny, GLfixed nz);                                           \
    void normalPointer(VertexAttribType typePacked, GLsizei stride, const void *pointer);        \
    void orthof(GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f);               \
    void orthox(GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);               \
    void pointParameterf(PointParameter pnamePacked, GLfloat param);                             \
    void pointParameterfv(PointParameter pnamePacked, const GLfloat *params);                    \
    void pointParameterx(PointParameter pnamePacked, GLfixed param);                             \
    void pointParameterxv(PointParameter pnamePacked, const GLfixed *params);                    \
    void pointSize(GLfloat size);                                                                \
    void pointSizex(GLfixed size);                                                               \
    void polygonOffsetx(GLfixed factor, GLfixed units);                                          \
    void popMatrix();                                                                            \
    void pushMatrix();                                                                           \
    void rotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);                                \
    void rotatex(GLfixed angle, GLfixed x, GLfixed y, GLfixed z);                                \
    void sampleCoveragex(GLclampx value, GLboolean invert);                                      \
    void scalef(GLfloat x, GLfloat y, GLfloat z);                                                \
    void scalex(GLfixed x, GLfixed y, GLfixed z);                                                \
    void shadeModel(ShadingModel modePacked);                                                    \
    void texCoordPointer(GLint size, VertexAttribType typePacked, GLsizei stride,                \
                         const void *pointer);                                                   \
    void texEnvf(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked, GLfloat param); \
    void texEnvfv(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked,                \
                  const GLfloat *params);                                                        \
    void texEnvi(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked, GLint param);   \
    void texEnviv(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked,                \
                  const GLint *params);                                                          \
    void texEnvx(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked, GLfixed param); \
    void texEnvxv(TextureEnvTarget targetPacked, TextureEnvParameter pnamePacked,                \
                  const GLfixed *params);                                                        \
    void texParameterx(TextureType targetPacked, GLenum pname, GLfixed param);                   \
    void texParameterxv(TextureType targetPacked, GLenum pname, const GLfixed *params);          \
    void translatef(GLfloat x, GLfloat y, GLfloat z);                                            \
    void translatex(GLfixed x, GLfixed y, GLfixed z);                                            \
    void vertexPointer(GLint size, VertexAttribType typePacked, GLsizei stride,                  \
                       const void *pointer);

#endif  // ANGLE_CONTEXT_API_1_0_AUTOGEN_H_


text:
package com.spotify.heroic.aggregation;

import com.google.common.base.Joiner;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.Lists;
import lombok.Data;

import java.util.List;
import java.util.ListIterator;

@Data
public class Chain implements Aggregation {
    public static final String NAME = "chain";
    public static final Joiner PIPE = Joiner.on(" | ");

    private final List<Aggregation> chain;

    @Override
    public AggregationInstance apply(final AggregationContext context) {
        ListIterator<Aggregation> it = chain.listIterator(chain.size());

        AggregationContext current = context;
        final ImmutableSet.Builder<String> tags = ImmutableSet.builder();

        final ImmutableList.Builder<AggregationInstance> chain = ImmutableList.builder();

        while (it.hasPrevious()) {
            final AggregationInstance instance = it.previous().apply(current);
            tags.addAll(instance.requiredTags());
            current = current.withRequiredTags(tags.build());
            chain.add(instance);
        }

        return ChainInstance.fromList(Lists.reverse(chain.build()));
    }

    public static Aggregation fromList(final List<Aggregation> chain) {
        final List<Aggregation> c = flattenChain(chain);

        if (c.size() == 1) {
            return c.iterator().next();
        }

        return new Chain(c);
    }

    private static List<Aggregation> flattenChain(
        final List<Aggregation> chain
    ) {
        final ImmutableList.Builder<Aggregation> child = ImmutableList.builder();

        for (final Aggregation a : chain) {
            if (a instanceof Chain) {
                child.addAll(flattenChain(Chain.class.cast(a).getChain()));
            } else {
                child.add(a);
            }
        }

        return child.build();
    }
}


text:
using System;

namespace Azure.ResourceManager.RecoveryServicesBackup.Models
{
    /// <summary> Container for SQL workloads under Azure Virtual Machines. </summary>
    public partial class AzureVmAppContainerProtectionContainer : AzureWorkloadContainer
    {
        /// <summary> Initializes a new instance of AzureVmAppContainerProtectionContainer. </summary>
        public AzureVmAppContainerProtectionContainer()
        {
            ContainerType = ProtectableContainerType.VmAppContainer;
        }

        /// <summary> Initializes a new instance of AzureVmAppContainerProtectionContainer. </summary>
        /// <param name="friendlyName"> Friendly name of the container. </param>
        /// <param name="backupManagementType"> Type of backup management for the container. </param>
        /// <param name="registrationStatus"> Status of registration of the container with the Recovery Services Vault. </param>
        /// <param name="healthStatus"> Status of health of the container. </param>
        /// <param name="containerType">
        /// Type of the container. The value of this property for: 1. Compute Azure VM is Microsoft.Compute/virtualMachines 2.
        /// Classic Compute Azure VM is Microsoft.ClassicCompute/virtualMachines 3. Windows machines (like MAB, DPM etc) is
        /// Windows 4. Azure SQL instance is AzureSqlContainer. 5. Storage containers is StorageContainer. 6. Azure workload
        /// Backup is VMAppContainer
        /// </param>
        /// <param name="protectableObjectType"> Type of the protectable object associated with this container. </param>
        /// <param name="sourceResourceId"> ARM ID of the virtual machine represented by this Azure Workload Container. </param>
        /// <param name="lastUpdatedOn"> Time stamp when this container was updated. </param>
        /// <param name="extendedInfo"> Additional details of a workload container. </param>
        /// <param name="workloadType"> Workload type for which registration was sent. </param>
        /// <param name="operationType"> Re-Do Operation. </param>
        internal AzureVmAppContainerProtectionContainer(string friendlyName, BackupManagementType? backupManagementType, string registrationStatus, string healthStatus, ProtectableContainerType containerType, string protectableObjectType, string sourceResourceId, DateTimeOffset? lastUpdatedOn, AzureWorkloadContainerExtendedInfo extendedInfo, WorkloadType? workloadType, OperationType? operationType) : base(friendlyName, backupManagementType, registrationStatus, healthStatus, containerType, protectableObjectType, sourceResourceId, lastUpdatedOn, extendedInfo, workloadType, operationType)
        {
            ContainerType = containerType;
        }
    }
}


text:
export const host = 'http://localhost';

//export const hostServer = 'http://classpip.upc.edu';
//export const host = 'http://classpip.upc.edu';

export const ImagenesColeccion = host + ':3000/api/imagenes/ImagenColeccion/download/';
export const ImagenesCromo = host + ':3000/api/imagenes/ImagenCromo/download/';

export const ImagenesAvatares = host + ':3000/api/imagenes/ImagenesAvatares/download/';

export const AudiosAvatares = host + ':3000/api/imagenes/AudiosAvatares/download/';
export const ImagenesAlumno = host + ':3000/api/imagenes/ImagenAlumno/download/';
export const ImagenesPerfil = host + ':3000/api/imagenes/ImagenesPerfil/download/';
export const LogosEquipos = host + ':3000/api/imagenes/LogosEquipos/download/';
export const ImagenesPregunta = host + ':3000/api/imagenes/ImagenesPreguntas/download/';

// export const Servidor = hostServer + ':8200';
export const Servidor = "";


text:
import argparse
import sys
import time

from ros2run.api import run_executable

def main():
    parser = argparse.ArgumentParser(description='Delay and execute an executable.')
    parser.add_argument('delay', metavar='T', type=float, help='Start delay in ms')
    parser.add_argument('executable', metavar='exec', type=str, nargs='+',
                        help='Executable to execute, with a variable number of arguments.')
    args = parser.parse_args()

    delay_time = args.delay * 0.001
    time.sleep(delay_time)
    # use ros2run api to handle KeyboardInterrupt
    return run_executable(path=args.executable[0], argv=args.executable[1:])

if __name__ == '__main__':
    sys.exit(main())


text:
[Apache Flink](https://flink.apache.org/) is an open source platform for distributed stream and batch data processing. Apache Flink comes with native Mesos support and can be also installed a DC/OS service

- Estimated time for completion: 5 minutes
- Target audience: Data engineers; basic knowledge of Apache Flink and DC/OS is helpful, but not required.
- Scope: Install and use Flink.

**Table of Contents**:

- [Prerequisites](#prerequisites)
- [Install Apache Flink](#install-flink)
- [Use Apache Flink](#use-flink)
- [Uninstall Apache Flink](#uninstall-flink)

## Prerequisites

- A running DC/OS 1.10 cluster with 1 agents with each 2 CPU and 2 GB of RAM available.
- [DC/OS CLI](https://dcos.io/docs/1.10/usage/cli/install/) installed.

## Install Flink

To install Apache Flink, do:

```bash
$ dcos package install flink
By Deploying, you agree to the Terms and Conditions https://mesosphere.com/catalog-terms-conditions/#community-services
This DC/OS Service is currently in preview. There may be bugs, incomplete features, incorrect documentation, or other discrepancies. Flink requires by default 2 CPUs with 2GB of RAM on private nodes.
Continue installing? [yes/no] yes
Installing Marathon app for package [flink] version [1.3.1-1.2-1.2]
Installing CLI subcommand for package [flink] version [1.3.1-1.2-1.2]
New command available: dcos flink
DC/OS Flink is being installed!

	Documentation: https://ci.apache.org/projects/flink/flink-docs-release-1.3/
```

**NOTE**: If your ***DCOS SLAVE NODES*** have not internet access to download required image to TaskManager instances from registry-1.docker.io, it's needed the inclusion of environment variable on service configuration to download image from local universe registry services:
```
FLINK_EXTRA_ARGS="-Dmesos.resourcemanager.tasks.container.image.name=master.mesos:5000/openjdk:8-jre"
```

After this, you should see the Flink service running via the `Services` tab of the DC/OS UI:

![Flink DC/OS service](img/services.png)

### Scala 2.11

Note, that the default build of Apache Flink and this universe package are both using Scala 2.10.

If you require Scala 2.11 please use the following install option from the UI (or via options.json when using the CLI):
![Scala 2.11](img/scala2_11.png)

## Use Flink

NOTE: In order to have better access to the input and output files, it makes sense to store those in HDFS.

### Upload Jar file via Flink UI
In the following we will use the DC/OS [Admin Router](https://dcos.io/docs/1.10/development/dcos-integration/#-a-name-adminrouter-a-admin-router) to provide access to the Flink UI: use the URL `http://$DCOS_DASHBOARD/service/flink/` and replace `$DCOS_DASHBOARD` with the URL of your DC/OS UI. Alternatively, you can also click `Open Service` in the DC/OS UI. The Flink dashboard UI looks like below.

![Flink Dashboard](img/dashboard.png)

Let us start our first job by going to `Submit new Job` in the Flink UI. We first need to add the respective jar file. For this example we will use the WordCount example jar file which can be found in `flink/build-target/examples/batch/WordCount.jar`.

### Run Jobs

#### Run Jobs via Flink UI

Next, we can define our job as shown below:

![Submit Flink Job](img/submit.png)

After the job has finished we should be able to see some details about the WordCount job:

![Finished Flink Job](img/finished.png)

#### Run Jobs via DC/OS Flink CLI

1. Submit the jar file via the CLI using `dcos flink upload`

```
$ dcos flink upload examples/WordCount.jar
http://m1.dcos/service/flink/jars/upload
{"status": "success", "filename": "c552ce76-ab00-48bf-8146-99d8c0114676_WordCount.jar"}
```

2. Find the jar id of the jar file that you wish to run using `dcos flink jars`

```
$ dcos flink jars
{
  "address": "http://a1.dcos:9149",
  "files": [
    {
      "id": "be38ffc9-dd6a-44dd-ae9f-449a3dcb39a4_WordCount.jar",
      "name": "WordCount.jar",
      "uploaded": 1508961041000,
      "entry": [
        {
          "name": "org.apache.flink.examples.java.wordcount.WordCount",
          "description": "No description provided"
        }
      ]
    },
    {
      "id": "c552ce76-ab00-48bf-8146-99d8c0114676_WordCount.jar",
      "name": "WordCount.jar",
      "uploaded": 1508961280000,
      "entry": [
        {
          "name": "org.apache.flink.examples.java.wordcount.WordCount",
          "description": "No description provided"
        }
      ]
    }
  ]
}
```

3. Call `dcos flink run <jar id>`
```
$ dcos flink run c552ce76-ab00-48bf-8146-99d8c0114676_WordCount.jar
{
  "jobid": "897bca2e8f6bbd99b9f217769dc6d149"
}

```
If successful, the terminal will return a job id.

4. To verify that the job has finished, call `dcos flink list`

```
$ dcos flink list
{
  "jobs-running": [],
  "jobs-finished": [
    "f483430a59f632b1ae9671e1883dd5db",
    "897bca2e8f6bbd99b9f217769dc6d149"
  ],
  "jobs-cancelled": [],
  "jobs-failed": []
}

```
Notice that our job has successfully finished.

## Uninstall Flink

To uninstall Flink:

```bash
$ dcos package uninstall flink
```
## Troubleshooting

### AWS Specific Config

There is a situation which can occur where the JobMaster is not able to resolve its hostname.  This causes the TaskManager container that launches to never communicate with the JobManager and the cluster never enters the ready state.
In the logs will contain something similar to

```
2017-07-29 17:10:05,553 ERROR org.apache.flink.mesos.runtime.clusterframework.MesosApplicationMasterRunner  - Mesos JobManager initialization failed
java.net.UnknownHostException: agentname: agentname: Name or service not known
    at java.net.InetAddress.getLocalHost(InetAddress.java:1505)
```

This can be resolved by [enabling "DNS Hostname" support in the VPC](https://www.ericmichaelstone.com/?p=7430) for the agents.

```
aws ec2 modify-vpc-attribute --vpc-id vpc-a01106c2 --enable-dns-hostnames "{\"Value\":true}"
```


text:
class JsonResponse {
  constructor(statusCode, message) {
    this.statusCode = statusCode;
    this.headers = {
      "Access-Control-Allow-Origin": "*",
      "Content-Type": "application/json",
    };
    this.body = JSON.stringify({ statusCode, message });
  }
}

module.exports = JsonResponse;


text:
package com.scaleunlimited.classify.datum;

import java.util.HashMap;
import java.util.Map;

import cascading.tuple.Fields;
import cascading.tuple.Tuple;

import com.scaleunlimited.classify.BaseModel;
import com.scaleunlimited.classify.analyzer.TextDatumAnalyzer;

/**
 * Input to the classification model ({@link BaseModel} subclass)
 * for a single document (likely originating through the analysis of a
 * single {@link TextDatum} by an analyzer ({@link TextDatumAnalyzer} subclass).
 * Training documents should have non-null labels.
 */
@SuppressWarnings("serial")
public class TermsDatum extends LabeledDatum {

    public static final String TERMS_FN = fieldName(TermsDatum.class, "terms");
    public static final String TERM_COUNTS_FN = fieldName(TermsDatum.class, "termcounts");

    public static final Fields FIELDS =
        LabeledDatum.FIELDS.append(new Fields(  TERMS_FN,
                                                TERM_COUNTS_FN));

    public TermsDatum(Fields fields) {
        super(fields);
    }

    public TermsDatum(Tuple tuple) {
        super(FIELDS, tuple);
    }

    public TermsDatum(Fields fields, Tuple tuple) {
        super(fields, tuple);
    }

    public TermsDatum(Map<String, Integer> termMap) {
        super(FIELDS);
        setTermMap(termMap);
        setLabel(BaseModel.NOT_YET_LABELED);
    }

    public TermsDatum(Map<String, Integer> termMap, String label) {
        super(FIELDS);
        super.setLabel(label);
        setTermMap(termMap);
    }

    public Map<String, Integer> getTermMap() {
        Tuple termsTuple = (Tuple)_tupleEntry.getObject(TERMS_FN);
        Tuple termCountsTuple = (Tuple)_tupleEntry.getObject(TERM_COUNTS_FN);
        int numTerms = termsTuple.size();
        Map<String, Integer> result = new HashMap<String, Integer>(numTerms);
        for (int i = 0; i < numTerms; i++) {
            result.put(termsTuple.getString(i), termCountsTuple.getInteger(i));
        }
        return result;
    }

    public void setTermMap(Map<String, Integer> termMap) {
        Tuple termsTuple = new Tuple();
        Tuple termCountsTuple = new Tuple();
        for (Map.Entry<String, Integer> entry : termMap.entrySet()) {
            termsTuple.add(entry.getKey());
            termCountsTuple.add(entry.getValue());
        }
        _tupleEntry.set(TERMS_FN, termsTuple);
        _tupleEntry.set(TERM_COUNTS_FN, termCountsTuple);
    }
}


text:
package io.skysail.server.app.plugins.features;

public enum FeatureStatus {
	AVAILABLE, INSTALLED, UNINSTALLABLE
}


text:
package org.auraframework.integration.test.error;

import static org.hamcrest.CoreMatchers.containsString;
import static org.junit.Assert.assertThat;

import org.auraframework.system.AuraContext.Mode;

public class ServerModelErrorUITest extends AbstractErrorUITestCase {

    public ServerModelErrorUITest(String name) {
        super(name);
    }

    /**
     * Verify Aura default error handler can handle systemError when an exception is thrown from model.
     */
    public void testDefaultHandleErrorInModelWhenSerialize() throws Exception {
        open("/auratest/errorHandlingErrorModelApp.app", Mode.PROD, false);

        String actualMessage = findErrorMessage();
        String expectedMsg = "Failed to initialize application";
        assertThat("Error modal doesn't contain expected message", actualMessage, containsString(expectedMsg));
    }
}


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Authorization;

namespace aspCart.Web.Areas.Admin.Controllers
{
    [Area("Admin")]
    [Authorize(Roles = "Admin")]
    public class AdminController : Controller { }
}


text:
package collect;

import com.google.common.base.Preconditions;
import com.google.common.base.Predicate;
import com.google.common.collect.Iterables;

/**
 * Static utility methods which operate on or return {@link Iterable}s.
 *
 * @author Zhenya Leonov
 * @see Iterables
 *
 */
public final class Iterables2 {

	private Iterables2() {
	}

	/**
	 * Returns the number of elements in the given {@code Iterable} which
	 * satisfy the specified {@code Predicate}.
	 *
	 * @param <E>
	 *            the type of elements in the provided {@code Iterable}
	 * @param iterable
	 *            the provided {@code Iterable}
	 * @param predicate
	 *            the specified {@code Predicate}
	 * @return the number of elements in {@code iterable} which satisfy
	 *         {@code predicate}
	 */
	public static <E> int countIf(final Iterable<E> iterable,
			final Predicate<? super E> predicate) {
		Preconditions.checkNotNull(iterable);
		Preconditions.checkNotNull(predicate);
		int count = 0;
		for (E element : iterable)
			if (predicate.apply(element))
				count++;
		return count;
	}

	/**
	 * Returns the number of elements in the given {@code Iterable} which do not
	 * satisfy the specified {@code Predicate}.
	 *
	 * @param <E>
	 *            the type of elements in the provided {@code Iterable}
	 * @param iterable
	 *            the provided {@code Iterable}
	 * @param predicate
	 *            the the specified {@code Predicate}
	 * @return the number of elements in {@code iterable} which do not satisfy
	 *         {@code predicate}
	 */
	public static <E> int countIfNot(final Iterable<E> iterable,
			final Predicate<? super E> predicate) {
		Preconditions.checkNotNull(iterable);
		Preconditions.checkNotNull(predicate);
		int count = 0;
		for (E element : iterable)
			if (!predicate.apply(element))
				count++;
		return count;
	}

}