当前位置: 首页>>代码示例>>C#>>正文


C# Brand类代码示例

本文整理汇总了C#中Brand的典型用法代码示例。如果您正苦于以下问题:C# Brand类的具体用法?C# Brand怎么用?C# Brand使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Brand类属于命名空间,在下文中一共展示了Brand类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SetUpData

        private void SetUpData()
        {
            Domain.Dependencies.Register();

            //Repository registration
            DIContainer.Instance.RegisterType<IRepository, OnlineRepository>(OnlineRepository.InstanceName);
            DIContainer.Instance.RegisterType<ReferenceDataRepository>(new ContainerControlledLifetimeManager());
            DIContainer.Instance.RegisterType<IComponentSettingsClient, ComponentSettingsClientTest>();

            var workStation = DIContainer.Instance.Resolve<Workstation>();
            workStation.ConfigurationServiceBaseAddress = "http://Localhost/";
            workStation.Ship = new Ship { ShipId = "1", BrandId = "3", Code = "3" };
            workStation.ConnectionMode = ConnectionMode.Online;
            var intCollection = new Collection<int>();
            intCollection.Add(1);
            intCollection.Add(2);
            intCollection.Add(3);
            var brand = new Brand { BrandId = "3", Name = "Carnival Breeze", MediaItemAddress = "http://172.26.248.122/ImagingMediaService/MediaItems/23" };
            brand.AssignPortIds(intCollection);
            workStation.Brand = brand;
            workStation.Voyage = new Voyage { IsActive = true, VoyageId = "31", Number = "dd0", ShipId = "1" };
            var voyages = new List<Voyage>();
            voyages.Add(new Voyage { IsActive = true, VoyageId = "31", Number = "dd0", ShipId = "1" });
            workStation.AssignVoyageList(voyages);

            this.targetRepository = new ConfigurationServiceRepository();
        }
开发者ID:JaipurAnkita,项目名称:mastercode,代码行数:27,代码来源:ConfigurationServiceRepositoryTest.cs

示例2: addimage

        protected override void addimage(location state, Brand brand, RotateFlipType rotate)
        {
            Bitmap bitmap;
            // �p�G�O�i�����P�N�]�w��ܵP���ϫ��A�_�h�N��ܪ��ߪ��P Resources.upbarnd
            if (brand.IsCanSee || state == location.South || ShowAll)
                bitmap = new Bitmap(brand.image);
            else
                bitmap = new Bitmap(Resources.upbarnd);
            // �]�w�P
            BrandBox tempBrandbox = new BrandBox(brand);

            // �]�w�۰��Y��
            tempBrandbox.SizeMode = PictureBoxSizeMode.AutoSize;

            // �]�w��Z
            tempBrandbox.Margin = new Padding(0);
            tempBrandbox.Padding = new Padding(padding);

            // �n�઺����
            bitmap.RotateFlip(rotate);

            // ����
            if (ShowAll && ShowBrandInfo)
                tempBrandbox.Click += new EventHandler(debug_Click);

            // �ƹ��ƥ�
            if (
                state == location.South
                && brand.getClass() != Settings.Default.Flower
                && brand.Team < 1
                )
            {
                tempBrandbox.MouseMove += new MouseEventHandler(tempBrandbox_MouseMove);
                tempBrandbox.MouseLeave += new EventHandler(brandBox_MouseLeave);
                tempBrandbox.Click += new EventHandler(brandBox_MouseClick);

                // �@���ƥ�
                //if (ShowAll && ShowBrandInfo)
                //    tempBrandbox.MouseHover += new EventHandler(debug_Click);
                //else
                //    tempBrandbox.MouseHover -= new EventHandler(debug_Click);
            }
            else if (cheat && state != location.South)
            {
                tempBrandbox.MouseClick += new MouseEventHandler(cheat_MouseClick);
            }
            else
            {
                tempBrandbox.Click -= new EventHandler(brandBox_MouseClick);
                tempBrandbox.MouseClick -= new MouseEventHandler(cheat_MouseClick);

            }
            bitmap = ResizeBitmap(bitmap, Settings.Default.ResizePercentage);

            // �]�w�Ϥ�
            tempBrandbox.Image = bitmap;

            // �s�W�ܱ��
            add_flowLayoutBrands(state, tempBrandbox);
        }
开发者ID:billteng,项目名称:mahjong,代码行数:60,代码来源:NewTable.cs

示例3: chackBrandNumber

 private bool chackBrandNumber(Brand b1,Brand b2)
 {
     if (b1.getNumber() == b2.getNumber())
         return true;
     else
         return false;
 }
开发者ID:billteng,项目名称:mahjong,代码行数:7,代码来源:BrandsTest.cs

示例4: status

 public void status()
 {
     Brand objbrand = new Brand();
     string type = Request.QueryString["dl"];
     string brandid = Request.QueryString["id"];
     objbrand.UpdatebyID(int.Parse(brandid), int.Parse(type));
 }
开发者ID:ziad007,项目名称:URI3,代码行数:7,代码来源:Brandlisting.aspx.cs

示例5: SalvarBrand

        public ActionResult SalvarBrand(Brand brand)
        {
            ViewBag.Message = "Marcas de Coche";
            SaveEntity(brand);

            return base.View("Nuevo", brand);
        }
开发者ID:rfrancis1976,项目名称:MOTORLAM,代码行数:7,代码来源:BrandController.cs

示例6: getBrands

        public static List<Brand> getBrands()
        {
            try
            {
                SQLHelper dbhelper = new SQLHelper();

                List<MySqlParameter> lstParameter = new List<MySqlParameter>();

                var resultSet = dbhelper.executeSP<DataSet>(lstParameter, "SelectAllBrand");

                List<Brand> brands = new List<Brand>();
                foreach (DataRow drow in resultSet.Tables[0].Rows)
                {
                    Brand brand = new Brand();
                    brand.BrandID = Convert.ToInt32(drow["brandId"].ToString());
                    brand.Brandname = drow["brandname"].ToString();
                    brand.Description = drow["description"].ToString();

                    brands.Add(brand);
                }

                return brands;
            }
            catch (Exception e)
            {
                throw e;
            }
        }
开发者ID:niyomja,项目名称:laksi-tractor,代码行数:28,代码来源:BrandDAL.cs

示例7: Create

        /// <summary>
        /// 新增
        /// </summary>
        /// <param name="brandEditVM"></param>
        /// <returns></returns>
        public ErrorCode Create(BrandEditVM brandEditVM)
        {
            try
            {
                if (BrandDal.GetExisted(o => o.CommodityTypeId == brandEditVM.CommodityTypeId && o.Name == brandEditVM.Name))
                {
                    return ErrorCode.BrandExisted;
                }

                var brand = new Brand
                {
                    Name = brandEditVM.Name,
                    CommodityTypeId = brandEditVM.CommodityTypeId,
                    Description = brandEditVM.Description,
                    CommodityId = brandEditVM.CommodityId
                };

                BrandDal.Create(brand);
                return ErrorCode.NoError;
            }
            catch (Exception)
            {
                return ErrorCode.ServerError;
            }
        }
开发者ID:jesusblessf6,项目名称:Maike,代码行数:30,代码来源:BrandService.cs

示例8: InsertManufacturer

 public void InsertManufacturer()
 {
     var manufacturer = new Manufacturer();
     manufacturer.Name = "Manufacturer1";
     ManufacturerDAO.Instance.Save(manufacturer);
     var brand = new Brand {Name = "Brand1", Manufacturer = manufacturer};
     BrandDAO.Instance.Save(brand);
 }
开发者ID:vincentzh,项目名称:nhibernate-burrow-with-dapper,代码行数:8,代码来源:DapperTest.cs

示例9: chackBrandClass

 private bool chackBrandClass(Brand b1, Brand b2)
 {
     if (b1.getClass() == b2.getClass())
         return true;
     else
     {
         return false;
     }
 }
开发者ID:billteng,项目名称:mahjong,代码行数:9,代码来源:BrandsTest.cs

示例10: Edit

 public ActionResult Edit(Brand brand)
 {
     if (ModelState.IsValid)
     {
         _daoFactory.BrandDao().SaveOrUpdate(brand);
         return Redirect("index");
     }
     return View(brand);
 }
开发者ID:luqizheng,项目名称:OrnamentFramework,代码行数:9,代码来源:BrandController.cs

示例11: CheckBrands

 /// <summary>
 /// �P�����A�ˬd �Y �I �b �J
 /// </summary>
 /// <param name="otherbrand">�i�Ӫ��P</param>
 /// <param name="player">���ߪ����a�զX</param>
 public CheckBrands(Brand otherbrand, BrandPlayer player)
 {
     for (int i = 0; i < player.getCount(); i++)
         if (player.getBrand(i).getClass() != Mahjong.Properties.Settings.Default.Flower)
             x.add(player.getBrand(i));
     brand = otherbrand;
     for (int i = 0; i < chow_player.Length; i++)
         chow_player[i] = new BrandPlayer();
 }
开发者ID:billteng,项目名称:mahjong,代码行数:14,代码来源:CheckBrands.cs

示例12: UpdateBrand

 public Brand UpdateBrand(Brand updatedBrand)
 {
     var brandToUpdate = _brandRepository.FindOne(b => b.Id == updatedBrand.Id);
     SetOwner(brandToUpdate, updatedBrand.CompanyId);
     brandToUpdate.BrandName = updatedBrand.BrandName;
     brandToUpdate.LastUpdated = DateTime.Now;
     _brandRepository.Persist();
     Log.Debug("Brand {0} with Id {1} updated", brandToUpdate.BrandName, brandToUpdate.Id);
     return brandToUpdate;
 }
开发者ID:consumentor,项目名称:Server,代码行数:10,代码来源:BrandApplicationService.cs

示例13: CheckUser

 public CheckUser(bool chow,bool pong,bool kong,bool darkkong,bool win,bool pass,Brand brand)
 {
     Chow = chow;
     Pong = pong;
     Kong = kong;
     DarkKong = darkkong;
     Win = win;
     Pass = pass;
     Brand = brand;
 }
开发者ID:Superbil,项目名称:mahjong,代码行数:10,代码来源:CheckUser.cs

示例14: listingtblbody

    public void listingtblbody()
    {
        Brand objbrand = new Brand();
        string page = Request.QueryString["Page"];
        if (page == null) page = "1";
        int HOWMANYPAGES = 0;
        List<Brand> objbrandlisting = objbrand.getBrandall(true,9 ,page.ToString(), "20", out  HOWMANYPAGES);

        Table tblbrand = new Table();

        tblbrand.Width = Unit.Percentage(100);
        tblbrand.CellPadding = 0;
        tblbrand.CellSpacing = 0;
        tblbrand.BorderWidth = 0;
        TableRow tblrow = new TableRow();
        TableCell tblcell = new TableCell();
        int sum = 0;
        for (int i = 0; i < objbrandlisting.Count; i++)
        {
            tblrow.HorizontalAlign = HorizontalAlign.Center;
            tblcell = new TableCell();
            tblcell.Style.Add("background", "white");
            string Brandid = objbrandlisting[i].BrandID;
            string logo = objbrandlisting[i].Logo;
            Image imag = new Image();
            imag.Width = 190;
            imag.Height = 190;
            imag.ImageUrl = "~/images/" + objbrandlisting[i].Logo;
            imag.Attributes.Add("onclick", "javascript:window.open('Branddetail.aspx?id=" + Brandid + "');");
            tblcell.Controls.Add(imag);
            tblrow.Cells.Add(tblcell);

            sum = sum + 1;
            if (sum == 5)
            {
                tblbrand.Controls.Add(tblrow);
                tblrow = new TableRow();
                sum = 0;
            }

            else
            {
                tblbrand.Controls.Add(tblrow);
            }
        }

        phbrand.Controls.Add(tblbrand);

        string firstPageUrl = "http://localhost/fuck/Brand/Brandlisting.aspx?";

        //SHARIF Page={0} shoule be like this
        string pagerFormat = "http://localhost/fuck/Brand/Brandlisting.aspx?Page={0}";

        bottomPager.Show(int.Parse(page), HOWMANYPAGES, firstPageUrl, pagerFormat, true);
    }
开发者ID:ziad007,项目名称:URI3,代码行数:55,代码来源:Brandlisting.aspx.cs

示例15: getReadyBrand

 /// <summary>
 /// ��P
 /// </summary>
 /// <returns></returns>
 public Brand getReadyBrand()
 {
     ans = player.getBrand(0);
     for (int i = 1; i < player.getCount(); i++)
     {
         if (player.getBrand(i).Source < ans.Source && player.getBrand(i).getClass() != Mahjong.Properties.Settings.Default.Flower)
             ans = player.getBrand(i);
     }
     //print();
     return ans;
 }
开发者ID:billteng,项目名称:mahjong,代码行数:15,代码来源:Level+1.cs


注:本文中的Brand类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。