Exemple #1
0
        public static List <Casopis> DohvatiSve()
        {
            List <Casopis> listaCasopisa = new List <Casopis>();

            BP.otvoriKonekciju();

            SqliteCommand command = BP.komanda();

            command.CommandText = "Select * from casopis, sadrzaj where casopis.id_sadrzaj = sadrzaj.id";

            SqliteDataReader reader = command.ExecuteReader();

            while (reader.Read())
            {
                Casopis k = new Casopis();

                k.Id     = (int)(Int64)reader["id"];
                k.Naziv  = (string)reader["naziv"];
                k.Tagovi = (string)reader["tagovi"];

                listaCasopisa.Add(k);
            }

            reader.Dispose();
            command.Dispose();

            return(listaCasopisa);
        }
Exemple #2
0
        public void Restore()
        {
            // Delete old breakpoints
            foreach (Breakpoint BP in m_dte2.Debugger.Breakpoints)
            {
                if (m_file.CompareTo(BP.File) == 0)
                {
                    BP.Delete();
                }
            }
            foreach (BreakpointStorage BP in m_breakpointStorage)
            {
                try
                {
                    m_dte2.Debugger.Breakpoints.Add("", BP.file, BP.line, BP.column, BP.condition, BP.conditionType, BP.language, "", 0, "", BP.hitCount, BP.hitCountType);

                    foreach (Breakpoint DTEBP in m_dte2.Debugger.Breakpoints)
                    {
                        try
                        {
                            if ((DTEBP.File.CompareTo(BP.file) == 0) &&
                                (DTEBP.FileLine == BP.line))
                            {
                                DTEBP.Enabled = BP.enabled;
                            }
                        }
                        catch (Exception) { }
                    }
                }
                catch (Exception) { }
            }
        }
Exemple #3
0
 public void EditBP(BP bP)
 {
     bP.LastModifiedDateUtc = DateTime.UtcNow;
     bP.CreatedDateUtc      = DateTime.UtcNow;
     bP.LastModifiedBy      = 1;
     _repository.Update(bP);
 }
        public void Restore()
        {
            EnvDTE80.DTE2 dte2 = m_serviceProvider.GetService(typeof(EnvDTE.DTE)) as EnvDTE80.DTE2;

            // Delete old breakpoints
            foreach (Breakpoint BP in dte2.Debugger.Breakpoints)
            {
                if (m_file.CompareTo(BP.File) == 0)
                {
                    BP.Delete();
                }
            }
            foreach (BreakpointStorage BP in m_breakpointStorage)
            {
                try
                {
                    dte2.Debugger.Breakpoints.Add("", BP.file, BP.line, BP.column, BP.condition, BP.conditionType, BP.language, "", 0, "", BP.hitCount, BP.hitCountType);

                    foreach (Breakpoint DTEBP in dte2.Debugger.Breakpoints)
                    {
                        try
                        {
                            if ((DTEBP.File.CompareTo(BP.file) == 0) &&
                                (DTEBP.FileLine == BP.line))
                            {
                                DTEBP.Enabled = BP.enabled;
                            }
                        }
                        catch (Exception) { }
                    }
                }
                catch (Exception) { }
            }
        }
Exemple #5
0
 /// <summary>
 /// IHMSSI constructor
 /// </summary>
 /// <param name="leds">if changed PCF8574 SLA must be in [0x20, 0x27], PCF8574A in [0x38, 0x3F] and Frequency in [100kHz,400kHz]</param>
 /// <param name="BPs">if changed PCF8574 SLA must be in [0x20, 0x27], PCF8574A in [0x38, 0x3F] and Frequency in [100kHz,400kHz]</param>
 /// <param name="lcd">lcd is MIDAS(0x3A) or BATRON(0x3B), Frequency in [100kHz,400kHz]</param>
 /// <remarks>
 /// All Led => Off; Lcd => Init
 /// </remarks>
 public IHMSSI(PCF8574 leds, PCF8574 BPs, I2CLcd lcd)
 {
     this.leds = leds;
     this.BPs  = BPs;
     this.lcd  = lcd;
     d0        = new Led(false, 0, leds);
     d1        = new Led(false, 1, leds);
     d2        = new Led(false, 2, leds);
     d3        = new Led(false, 3, leds);
     d4        = new Led(false, 4, leds);
     d5        = new Led(false, 5, leds);
     d6        = new Led(false, 6, leds);
     d7        = new Led(false, 7, leds);
     bpPlus    = new BP(BPs, 1);
     bpFleHaut = new BP(BPs, 2);
     bpFleBas  = new BP(BPs, 4);
     bpMoins   = new BP(BPs, 8);
     bpSet     = new BP(BPs, 16);
     bpOk      = new BP(BPs, 32);
     bpEnter   = new BP(BPs, 64);
     bpEchap   = new BP(BPs, 128);
     leds.Write(0xff); // Leds Off
     lcd.Init();
     lcd.ClearScreen();
 }
Exemple #6
0
        public BP getBP(string bpCode)
        {
            BP _bp = new BP();

            DataTable dtBP = DI.DataService.getDataTable("SELECT * FROM \"@ACPM_INT_BP\" WHERE \"Code\" = '" + bpCode + "'");

            if (dtBP.Rows.Count > 0)
            {
                DataRow dr = dtBP.Rows[0];
                _bp.BPCode         = dr["Code"].ToString();
                _bp.BPName         = dr["Name"].ToString();
                _bp.BillingAddress = dr["U_BillingAddress"].ToString();

                _bp.BPGroup   = dr["U_BPGroup"].ToString();
                _bp.Email     = dr["U_Email"].ToString();
                _bp.Phone     = dr["U_Phone"].ToString();
                _bp.PostedSAP = dr["U_PostedSAP"].ToString();
                if (_bp.PostedSAP == "Y")
                {
                    _bp.PostedDt = Convert.ToDateTime(dr["U_PostedSAP"]);
                    _bp.SAPCode  = dr["U_SAPCode"].ToString();
                }
            }
            return(_bp);
        }
Exemple #7
0
        public BP Get(string id)
        {
            BPRepo SAPBP = new BPRepo();
            BP     _bp   = SAPBP.getBP(id);

            return(_bp);
        }
Exemple #8
0
        public List <BP> getBP()
        {
            List <BP> bps = new List <BP>();

            DataTable dtBP = DI.DataService.getDataTable("SELECT * FROM \"@ACPM_INT_BP\" ");

            foreach (DataRow dr in   dtBP.Rows)
            {
                BP _bp = new BP();
                _bp.BPCode         = dr["Code"].ToString();
                _bp.BPName         = dr["Name"].ToString();
                _bp.BillingAddress = dr["U_BillingAddress"].ToString();

                _bp.BPGroup   = dr["U_BPGroup"].ToString();
                _bp.Email     = dr["U_Email"].ToString();
                _bp.Phone     = dr["U_Phone"].ToString();
                _bp.PostedSAP = dr["U_PostedSAP"].ToString();
                if (_bp.PostedSAP == "Y")
                {
                    _bp.PostedDt = Convert.ToDateTime(dr["U_PostedSAP"]);
                    _bp.SAPCode  = dr["U_SAPCode"].ToString();
                }
                bps.Add(_bp);
            }
            return(bps);
        }
Exemple #9
0
        public void BackPropagationTest()
        {
            List <Data> dataset = new List <Data>();

            //FillOnes(dataset);
            //FillZeros(dataset);
            FillFour(dataset);

            Topology topology = new Topology(25, 1, 0.1, 15);

            Network  neuralNetwork = new Network(topology);
            Learning strategy      = new BP(neuralNetwork);

            neuralNetwork.learningStrategy = strategy;

            neuralNetwork.CreateLayers <ActFuncSigm>();
            var difference = neuralNetwork.Learn(dataset, 10000);

            List <double> results = new List <double>();

            foreach (var data in dataset)
            {
                var res = neuralNetwork.FeedForwardSignals(data.InputsSignals).Output;
                results.Add(res);
            }

            for (int i = 0; i < results.Count; i++)
            {
                double expected = Math.Round(dataset[i].Expected, 0);
                double actual   = Math.Round(results[i], 0);
                Assert.AreEqual(expected, actual);
            }
        }
    public static string BaseItem(this string self)
    {
        if (self.Length == 0)
        {
            return(self);
        }

        ICollection <string> baseterms = new List <string>();

        foreach (string term in self.Split(new char[] { ' ' }))
        {
            if (BP.Equals(term, ic))
            {
                continue;
            }

            if (BLUEPRINT.Similarity(term) > 0.666)
            {
                continue;
            }

            baseterms.Add(term);
        }
        return(string.Join(" ", baseterms.ToArray <string>()));
    }
Exemple #11
0
		public static List<Knjiga> DohvatiSve()
		{
			List<Film> listaFilmova = new List<Knjiga>();

			BP.otvoriKonekciju();

			SqliteCommand command = BP.komanda();

			command.CommandText = "Select * from film, sadrzaj where film.id_sadrzaj = sadrzaj.id";

			SqliteDataReader reader = command.ExecuteReader();

			while (reader.Read())
			{
				Film k = new Film();

				k.Id = (int)(Int64)reader["id"];
				k.Naziv = (string)reader["naziv"];
				k.Tagovi = (string)reader["tagovi"];

				listaFilmova.Add(k);
			}

			reader.Dispose();
			command.Dispose();

			return listaFilmova;
	}
        public override void ObjectEnteredCell(LiquidVolume Liquid, GameObject GO)
        {
            if (Liquid.MaxVolume != -1 || !GO.HasPart("Body") || !GO.PhaseAndFlightMatches(Liquid.ParentObject) || GO.GetIntProperty("Slimewalking") > 0 || Liquid.Volume > 1000)
            {
                return;
            }
            int num = 10 + (int)((double)(Liquid.ComponentLiquids[ID] * 5) / 1000.0);

            if (!GO.MakeSave("Agility,Toughness", num - GO.GetIntProperty("Stable"), null, null, "Unwanted Growth"))
            {
                BodyPart bp = null;

                GO.GetPart <Body>()._Body.ForeachPart(delegate(BodyPart BP){
                    if (BP.GetTotalMobility() > 0 && (bp == null || BP.GetTotalMobility() > bp.GetTotalMobility()))
                    {
                        bp = BP;
                    }
                });

                if (bp != null)
                {
                    if (GO.IsPlayer())
                    {
                        MessageQueue.AddPlayerMessage("&CYour " + bp.Name + " grow" + (bp.Plural?"":"s") + " a little!");
                    }
                    GO.pPhysics.Weight += 1;
                }
            }
        }
Exemple #13
0
        // POST api/values
        public RTNMANVAL Post([FromBody] BP value)
        {
            RTNMANVAL returnVal = null;

            SAPbobsCOM.Company oCompany = null;
            string             newKey   = "";

            try
            {
                oCompany = Company.GetCompany(Properties.Settings.Default.StrDbServer, Properties.Settings.Default.StrDbUserName, Properties.Settings.Default.StrDbPassword,
                                              Properties.Settings.Default.StrDbName, Properties.Settings.Default.StrSapB1UserName, Properties.Settings.Default.StrSapB1Password,
                                              Properties.Settings.Default.StrSapB1LicenseServer);

                newKey = Logic.SAP.SAP_BP.AddData(oCompany, value);

                returnVal = new RTNMANVAL()
                {
                    errorCode = "0",
                    message   = "Data has beed added",
                    value     = newKey
                };
            }
            catch (Exception e)
            {
                returnVal = new RTNMANVAL()
                {
                    errorCode = "-1",
                    message   = e.Message.ToString()
                };
            }
            return(returnVal);
        }
Exemple #14
0
        public static BP GetData(SAPbobsCOM.Company oCompany, string id)
        {
            Utils control = new Utils();

            string sql = " select CardCode, CardName,Currency,Address,DebPayAcct,CardType, " +
                         " (CASE WHEN CardType = 'C' Then 'Customer' " +
                         " WHEN CardType = 'S' Then 'Supplier' " +
                         " else 'Lead' " +
                         " end) as 'TypeName' " +
                         " from ocrd where CardCode = '" + id + "'";

            Recordset rs = control._IDU_Recordset(oCompany, sql);

            XDocument xDoc = new XDocument();

            xDoc = XDocument.Parse(rs.GetAsXML());
            XElement xEle = xDoc.Element("BOM").Element("BO").Element("ocrd").Element("row");

            BP model = new BP()
            {
                CardCode       = xEle.Element("CardCode").Value,
                CardName       = xEle.Element("CardName").Value,
                Address        = xEle.Element("Address").Value,
                Currency       = xEle.Element("Currency").Value,
                BPType         = xEle.Element("TypeName").Value,
                DebtPayAccount = xEle.Element("DebPayAcct").Value
            };

            return(model);
        }
Exemple #15
0
        public override void ApplyState(VObject obj)
        {
            base.ApplyState(obj);

            var t = (PathBoundedTextVObject)obj;

            t.BoundingPaths = BP != null?BP.Select(Path.FromSvgString).ToArray() : null;

            t.IsVertical = IV;
        }
        ////////////public static string GetParamFromParamInfo(System.Reflection.ParameterInfo pInfo)
        ////////////{
        ////////////    var parameterTypeString = CSUtility.Program.GetTypeSaveString(pInfo.ParameterType);
        ////////////    string strFlag = ":";
        ////////////    if (pInfo.IsOut)
        ////////////    {
        ////////////        strFlag = ":Out";
        ////////////        parameterTypeString = parameterTypeString.Remove(parameterTypeString.Length - 1);
        ////////////    }
        ////////////    else if (pInfo.ParameterType.IsByRef)
        ////////////    {
        ////////////        strFlag = ":Ref";
        ////////////        parameterTypeString = parameterTypeString.Remove(parameterTypeString.Length - 1);
        ////////////    }
        ////////////    else
        ////////////    {
        ////////////        var atts = pInfo.GetCustomAttributes(typeof(System.ParamArrayAttribute), false);
        ////////////        if (atts.Length > 0)
        ////////////        {
        ////////////            strFlag = ":Params";
        ////////////        }
        ////////////    }

        ////////////    return pInfo.Name + ":" + parameterTypeString + strFlag;
        ////////////}
        ////////////public static string GetParamFromMethodInfo(System.Reflection.MethodInfo info, string path)
        ////////////{
        ////////////    string strRet = path + "," + CSUtility.Program.GetTypeSaveString(info.ReflectedType) + "," + info.Name + ",";

        ////////////    System.Reflection.ParameterInfo[] parInfos = info.GetParameters();
        ////////////    if (parInfos.Length > 0)
        ////////////    {
        ////////////        foreach (var pInfo in parInfos)
        ////////////        {
        ////////////            strRet += GetParamFromParamInfo(pInfo) + "/";
        ////////////        }
        ////////////        strRet = strRet.Remove(strRet.Length - 1);   // 去除最后一个"/"
        ////////////    }

        ////////////    strRet += "," + CSUtility.Program.GetTypeSaveString(info.ReturnType);

        ////////////    return strRet;
        ////////////}

        ////////////static Dictionary<CSUtility.Helper.enCSType, Dictionary<string, System.Reflection.MethodInfo>> mMethodInfoWithParamKeyDic = new Dictionary<CSUtility.Helper.enCSType, Dictionary<string, System.Reflection.MethodInfo>>();

        ////////////public static System.Reflection.MethodInfo GetMethodInfoFromParam(string param)
        ////////////{
        ////////////    try
        ////////////    {
        ////////////        if (string.IsNullOrEmpty(param))
        ////////////            return null;


        ////////////        bool isGenericMethodDefinition = false;
        ////////////        var splits = param.Split(',');
        ////////////        CSUtility.Helper.enCSType csType = CSUtility.Helper.enCSType.All;
        ////////////        if (splits.Length > 5)
        ////////////            csType = (CSUtility.Helper.enCSType)CSUtility.Support.IHelper.EnumTryParse(typeof(CSUtility.Helper.enCSType), splits[5]);

        ////////////        Dictionary<string, System.Reflection.MethodInfo> methodDic = null;
        ////////////        if (mMethodInfoWithParamKeyDic.TryGetValue(csType, out methodDic))
        ////////////        {
        ////////////            System.Reflection.MethodInfo retInfo = null;
        ////////////            if (methodDic.TryGetValue(param, out retInfo))
        ////////////                return retInfo;
        ////////////        }
        ////////////        else
        ////////////        {
        ////////////            methodDic = new Dictionary<string, System.Reflection.MethodInfo>();
        ////////////            mMethodInfoWithParamKeyDic[csType] = methodDic;
        ////////////        }

        ////////////        if (splits.Length > 6)
        ////////////            isGenericMethodDefinition = System.Convert.ToBoolean(splits[6]);
        ////////////        var path = splits[0];
        ////////////        var classType = CSUtility.Program.GetTypeFromSaveString(splits[1], csType);
        ////////////        if (classType == null)
        ////////////            return null;
        ////////////        var methodName = splits[2];

        ////////////        if (isGenericMethodDefinition)
        ////////////        {
        ////////////            var methods = classType.GetMethods();
        ////////////            foreach (var method in methods)
        ////////////            {
        ////////////                var methodParam = GetParamFromMethodInfo(method, path) + "," + csType.ToString() + "," + method.IsGenericMethodDefinition;
        ////////////                if (string.Equals(methodParam, param))
        ////////////                {
        ////////////                    methodDic[param] = method;
        ////////////                    return method;
        ////////////                }
        ////////////            }
        ////////////        }
        ////////////        if (!string.IsNullOrEmpty(splits[3]))
        ////////////        {
        ////////////            var paramSplits = splits[3].Split('/');
        ////////////            Type[] paramTypes = new Type[paramSplits.Length];
        ////////////            for (int i = 0; i < paramSplits.Length; i++)
        ////////////            {
        ////////////                var tempSplits = paramSplits[i].Split(':');
        ////////////                if (tempSplits.Length > 2)
        ////////////                {
        ////////////                    switch (tempSplits[2])
        ////////////                    {
        ////////////                        case "Ref":
        ////////////                        case "Out":
        ////////////                            tempSplits[1] += "&";
        ////////////                            break;
        ////////////                    }
        ////////////                }
        ////////////                paramTypes[i] = CSUtility.Program.GetTypeFromSaveString(tempSplits[1], csType);
        ////////////            }

        ////////////            var retValue = classType.GetMethod(methodName, paramTypes);
        ////////////            methodDic[param] = retValue;
        ////////////            return retValue;
        ////////////        }
        ////////////        else
        ////////////        {
        ////////////            var retValue = classType.GetMethod(methodName, new Type[0]);
        ////////////            methodDic[param] = retValue;
        ////////////            return retValue;
        ////////////        }
        ////////////    }
        ////////////    catch (System.Exception e)
        ////////////    {
        ////////////        EditorCommon.MessageReport.Instance.ReportMessage(EditorCommon.MessageReport.enMessageType.Error, "逻辑图:" + e.ToString());
        ////////////    }

        ////////////    return null;
        ////////////}

        partial void InitConstruction()
        {
            this.InitializeComponent();

            SetDragObject(RectangleTitle);
            mNodeContainer           = stackPanel_InputParams;
            mInputParamsPanel        = stackPanel_InputParams;
            mInputMethodParamsPanel  = stackPanel_InputMethodParams;
            mOutputMethodParamsPanel = stackPanel_OutputMethodParams;
            BP.Initialize(this);
        }
Exemple #17
0
        public static void Spremi(Casopis k)
        {
            BP.otvoriKonekciju();

            SqliteCommand command = BP.komanda();

            command.CommandText = @"create table if not exist Casopis (

			id integer primary key autoincrement,
			naziv string,
			tagovi string)"            ;
        }
Exemple #18
0
        public A1()
        {
            var a2 = new A2();
            var bp = new BP();
            //var bi = new BI();

            var a3 = new A3();

            a3.InternalMethod();
            a3.InternalProtectedMethod();
            a3.PublicMethod();
        }
        public static int BinaryCount(int[] arr, BP p)
        {
            int counter = 0;

            for (int i = 0; i != arr.Length - 1; ++i)
            {
                if (p(arr[i], arr[i + 1]))
                {
                    ++counter;
                }
            }
            return(counter);
        }
        public static int maxValue(int[] arr, BP p)
        {
            int maxEl = arr[0];

            for (int i = 0; i != arr.Length; ++i)
            {
                if (p(arr[i], maxEl))
                {
                    maxEl = arr[i];
                }
            }

            return(maxEl);
        }
Exemple #21
0
        /// <summary>
        /// Возвращает первого родителя заданного типа из цепочки родительских процессов
        /// </summary>
        /// <typeparam name="BP">Тип бизнес-процесса</typeparam>
        /// <returns>Типизированный бизнес-процесс или null, если процесс заданного типа не найден</returns>
        public BP GetParentOfType <BP>() where BP : class
        {
            if (this.ParentProcess == null)
            {
                return(default(BP));
            }
            BP cast = this.ParentProcess as BP;

            if (cast != null)
            {
                return(cast);
            }
            return(this.ParentProcess.GetParentOfType <BP>());
        }
Exemple #22
0
        public string Put([FromBody] BP value)
        {
            BPRepo SAPBP  = new BPRepo();
            string result = SAPBP.Update(value);

            if (result == "OK")
            {
                return("Posted Successfully");
            }
            else
            {
                return("Error in updating BP " + result);
            }
        }
Exemple #23
0
        public StandartCase CreateStandartCase(long BPId)
        {
            MainDBContext mainDB = new MainDBContext();

            BP bP = mainDB.BPs.FirstOrDefault(s => s.Id == BPId);

            if (bP == null)
            {
                return(null);
            }

            StandartCase standart = bP.StandartCase;

            return(standart);
        }
Exemple #24
0
        public static void Demo()
        {
            PCANetwork network = PCANetwork.Create(64, 8);

            var dataSet = DataGenerator.GenerateDataSet1();

            var pca = new PCA(network, 0.7);

            PCATrainer trainer = new PCATrainer(network, 50, pca, 0.00000005);

            Normalizer3 normalizer = new Normalizer3();

            //Normalizer normalizer = new Normalizer();

            normalizer.Fit(dataSet.XList);

            var normalizedX = normalizer.Normalize(dataSet.XList);


            Utils.DisplayListList(dataSet.XList);
            Console.WriteLine("--------------------------");
            Utils.DisplayListList(normalizedX);

            //Utils.DisplayListList(normalizer.DeNormalize(normalizedX));

            trainer.Fit(normalizedX);

            List <List <double> > convertedX = trainer.GetConvertedDim(normalizedX);

            //convertedX=normalizer.DeNormalize(convertedX);

            BPNetwork bpNetwork = BPNetwork.Create(8, new int[] { 4 /*, 4, 3*/ }, 3, ActivationFunction.SIGMOID, ActivationFunction.SIGMOID);

            var       bp        = new BP(bpNetwork, 0.6);
            BPTrainer bpTrainer = new BPTrainer(bpNetwork, 2000, bp);

            bpTrainer.Fit(convertedX, dataSet.YList);

            List <List <double> > predicted_ys = bpTrainer.Predict(convertedX);

            CorrectCalculator correctCalculator = new CorrectCalculator();

            var convertedPredictValue = NeuronOutputConverter.OrderInteger(predicted_ys);

            double correct = correctCalculator.Calculate(convertedPredictValue, dataSet.YList);

            Console.WriteLine("Score: {0}%", correct * 100);
        }
Exemple #25
0
		public static void Spremi(Film k)
		{
			BP.otvoriKonekciju();

			SqliteCommand command = BP.komanda();
			command.CommandText = @"create table if not exist film (

			id integer primary key autoincrement,
			godina DateTime,
			naziv string,
			trajanje integer,
			cijena double,
			tagovi string,
			opis string)"; 

		}
Exemple #26
0
        public string Update(BP _bp)
        {
            string    strUpdate = "UPDATE  \"@ACPM_INT_BP\"  SET \"Name\" = @Name,\"U_BPGroup\"=@U_BPGroup,\"U_BillingAddress\"=@U_BillingAddress,\"U_Email\"=@U_Email,\"U_Phone\"=@U_Phone WHERE @Code='" + _bp.BPCode + "'";
            Hashtable hp        = new Hashtable();

            hp.Add("@Code", _bp.BPCode);
            hp.Add("@Name", _bp.BPName);
            hp.Add("@U_BPGroup", _bp.BPGroup);
            hp.Add("@U_BillingAddress", _bp.BillingAddress);
            hp.Add("@U_Email", _bp.Email);
            hp.Add("@U_Phone", _bp.Phone);
            string result = DI.DataService.ExecuteNonQuery(strUpdate, hp);


            return(result);
        }
Exemple #27
0
    public void RootDestroyed(int Index)        //3
    {
        int Value = 0;

        for (int i = 0; i < GroundIndices.Count; i++)  //List of each ground part
        {
            if (Index == GroundIndices[i])
            {
                Value = i;
                foreach (BluePart BP in Parts)
                {
                    BP.RootDestroyed(Value);
                }
            }
        }
    }
Exemple #28
0
        public A1()
        {
            var a2 = new A2();
            var bp = new BP();
            //var bi = new BI();  // publicではなくinternalなのでエラーになる

            var a3 = new A3();

            // A3のメソッドがアクセス修飾子によってどう見えるか検証
            a3.InternalMethod();
            a3.InternalProtectedMethod();
            a3.PublicMethod();

            // 上記の例の場合、protected と private が見れていない
            // protected は 自分のクラスか継承先でしか見れない
            // private は 自分のクラスでしか見れない
        }
Exemple #29
0
        public void Save(String file, bool remove)
        {
            m_file = file;
            m_breakpointStorage.Clear();
            foreach (Breakpoint BP in m_dte2.Debugger.Breakpoints)
            {
                if (file.CompareTo(BP.File) == 0)
                {
                    m_breakpointStorage.Add(new BreakpointStorage(BP));

                    if (remove)
                    {
                        BP.Delete();
                    }
                }
            }
        }
Exemple #30
0
        public string PostBP(BP bpCode)
        {
            string insertBP = "INSERT INTO \"@ACPM_INT_BP\" ";

            insertBP += " (\"Code\",\"Name\",\"U_BPGroup\",\"U_BillingAddress\",\"U_Email\",\"U_Phone\")";
            insertBP += " VALUES (@Code,@Name,@U_BPGroup,@U_BillingAddress,@U_Email, @U_Phone)";
            Hashtable hp = new Hashtable();

            hp.Add("@Code", bpCode.BPCode);
            hp.Add("@Name", bpCode.BPName);
            hp.Add("@U_BPGroup", bpCode.BPGroup);
            hp.Add("@U_BillingAddress", bpCode.BillingAddress);
            hp.Add("@U_Email", bpCode.Email);
            hp.Add("@U_Phone", bpCode.Phone);
            string result = DI.DataService.ExecuteNonQuery(insertBP, hp);


            return(result);
        }