aboutsummaryrefslogtreecommitdiffstats
path: root/Software/PMR/Messages/EmbeddedParameters/MachineCalibrationDataRequest.proto
blob: c615edb3589803eb8b53761cbdc1c8d49c62ede7 (plain)
1
2
3
4
5
6
7
8
9
10
11
syntax = "proto3";

package Tango.PMR.EmbeddedParameters;
option java_package = "com.twine.tango.pmr.embeddedparameters";


message MachineCalibrationDataRequest
{

}
background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Xml.Serialization;
using Newtonsoft.Json;
using System.Linq;
using Tango.DAL.Remote.DB;

namespace Tango.BL.Entities
{
    [Table("@(Model.TableName)")]
    public partial class @(Model.Name) : ObservableEntity<@(Model.Name)>
    {
        @foreach (var prop in Model.Fields)
        {
    <div>
        protected @(prop.Type) _@(prop.Name.ToLower());
        /// <summary>
        /// Gets or sets the @(Model.Name.ToLower()) @(prop.Description).
        /// </summary>
        @(!prop.Construct && !prop.Complex ? "[Column(\"" + prop.FieldName + "\")]" : "")
        @(prop.IsForeignKey ? "[ForeignKey(\"" + prop.ForeignKeyName + "\")]" : "")
        @(prop.XmlIgnore ? "[XmlIgnore]" : "")
        @(prop.XmlIgnore ? "[JsonIgnore]" : "")
        public @(prop.Construct || prop.Complex ? "virtual" : "") @(prop.Type) @(prop.Name)
        {
            get { return _@(prop.Name.ToLower()); }
            set { _@(prop.Name.ToLower()) = value; RaisePropertyChanged(nameof(@(prop.Name))); }
        }
    </div>
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="@(Model.Name)" /> class.
        /// </summary>
        public @(Model.Name)() : base()
        {
            @foreach (var prop in Model.Fields)
            {
                if (prop.Construct)
                {
                    <div>
                        @(prop.Name) = new @(prop.Type)();
                    </div>
                }
            }
        }
    }
}