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


C# GenericReader.ReadString方法代码示例

本文整理汇总了C#中GenericReader.ReadString方法的典型用法代码示例。如果您正苦于以下问题:C# GenericReader.ReadString方法的具体用法?C# GenericReader.ReadString怎么用?C# GenericReader.ReadString使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在GenericReader的用法示例。


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

示例1: Deserialize

		public void Deserialize( GenericReader reader, int version )
		{
			switch( version )
			{
				case 2:
				{
					m_Description = reader.ReadString();

					goto case 1;
				}
				case 1:
				{
					m_BlessBond = reader.ReadBool();
					m_BBPrice = reader.ReadInt();

					goto case 0;
				}
				case 0:
				{
					m_Item = reader.ReadString();
					m_Name = reader.ReadString();
					m_Price = reader.ReadInt();
					m_Amount = reader.ReadInt();

					break;
				}
			}
		}
开发者ID:greeduomacro,项目名称:unknown-shard-1,代码行数:28,代码来源:VendorStone.cs

示例2: VendorInventory

        public VendorInventory(BaseHouse house, GenericReader reader)
        {
            this.m_House = house;

            int version = reader.ReadEncodedInt();

            this.m_Owner = reader.ReadMobile();
            this.m_VendorName = reader.ReadString();
            this.m_ShopName = reader.ReadString();

            this.m_Items = reader.ReadStrongItemList();
            this.m_Gold = reader.ReadInt();

            this.m_ExpireTime = reader.ReadDeltaTime();

            if (this.m_Items.Count == 0 && this.m_Gold == 0)
            {
                Timer.DelayCall(TimeSpan.Zero, new TimerCallback(Delete));
            }
            else
            {
                TimeSpan delay = this.m_ExpireTime - DateTime.Now;
                this.m_ExpireTimer = new ExpireTimer(this, delay > TimeSpan.Zero ? delay : TimeSpan.Zero);
                this.m_ExpireTimer.Start();
            }
        }
开发者ID:FreeReign,项目名称:forkuo,代码行数:26,代码来源:VendorInventory.cs

示例3: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				{
					m_House = reader.ReadItem() as BaseHouse;
					goto case 0;
				}
				case 0:
				{
					m_Description = reader.ReadString();
					m_Marked = reader.ReadBool();
					m_Target = reader.ReadPoint3D();
					m_TargetMap = reader.ReadMap();

					CalculateHue();

					break;
				}
			}
		}
开发者ID:nathanvy,项目名称:runuo,代码行数:26,代码来源:RecallRune.cs

示例4: LocationStruct

 public LocationStruct(GenericReader reader)
 {
     int version = reader.ReadInt();
     Map = reader.ReadMap();
     Location = reader.ReadPoint3D();
     Name = reader.ReadString();
 }
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:7,代码来源:SunnyToolbar.cs

示例5: BOBSmallEntry

		public BOBSmallEntry( GenericReader reader )
		{
			int version = reader.ReadEncodedInt();

			switch ( version )
			{
				case 0:
				{
					string type = reader.ReadString();

					if ( type != null )
						m_ItemType = ScriptCompiler.FindTypeByFullName( type );

					m_RequireExceptional = reader.ReadBool();

					m_DeedType = (BODType)reader.ReadEncodedInt();

					m_Material = (BulkMaterialType)reader.ReadEncodedInt();
					m_AmountCur = reader.ReadEncodedInt();
					m_AmountMax = reader.ReadEncodedInt();
					m_Number = reader.ReadEncodedInt();
					m_Graphic = reader.ReadEncodedInt();
					m_Price = reader.ReadEncodedInt();

					break;
				}
			}
		}
开发者ID:Godkong,项目名称:RunUO,代码行数:28,代码来源:BOBSmallEntry.cs

示例6: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();
         
            switch ( version )
            {
                case 1:
                    {
                        reader.ReadInt();
                        reader.ReadInt();
                        reader.ReadInt();
                        //this.m_TextColor = reader.ReadInt();
                        //this.m_TitleColor = reader.ReadInt();
                        //this.m_size = reader.ReadInt();
                    }
                    break;
                case 0:
                    {
                        reader.ReadString();
                        reader.ReadString();
                        reader.ReadInt();
                        reader.ReadInt();
                        reader.ReadInt();
                        //this.NoteString = reader.ReadString();
                        //this.TitleString = reader.ReadString();
                        //this.m_TextColor = reader.ReadInt();
                        //this.m_TitleColor = reader.ReadInt();
                        //this.m_size = reader.ReadInt();
                    }
                    break;
            }
        }
开发者ID:jasegiffin,项目名称:JustUO,代码行数:34,代码来源:QuestNote.cs

示例7: Deserialize

        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadInt();
            m_LabelNumber = reader.ReadInt();
            m_From = reader.ReadString();
            m_To = reader.ReadString();

            Utility.Intern(ref m_From);
            Utility.Intern(ref m_To);
        }
开发者ID:vexilar,项目名称:RunUO_Rebar,代码行数:12,代码来源:ValentinesCard.cs

示例8: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch( version )
			{
				case 3:
				{
					m_BeforeChangeover = reader.ReadBool();
					goto case 2;
				}
				case 2:
				{
					m_GuildName = reader.ReadString();
					m_GuildAbbrev = reader.ReadString();

					goto case 1;
				}
				case 1:
				{
					m_Guild = reader.ReadGuild() as Guild;

					goto case 0;
				}
				case 0:
				{
					break;
				}
			}

			if( Guild.NewGuildSystem && ItemID == 0xED4 )
				ItemID = 0xED6;

			if( m_Guild != null )
			{
				m_GuildName = m_Guild.Name;
				m_GuildAbbrev = m_Guild.Abbreviation;
			}

			if( version <= 2 )
				m_BeforeChangeover = true;

			if( Guild.NewGuildSystem && m_BeforeChangeover )
				Timer.DelayCall( TimeSpan.Zero, new TimerCallback( AddToHouse ) );

			if( !Guild.NewGuildSystem && m_Guild == null )
				this.Delete();
		}
开发者ID:jsrn,项目名称:MidnightWatchServer,代码行数:50,代码来源:Guildstone.cs

示例9: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();
            switch (version)
            {
                case 1:
                    this.m_Condition = reader.ReadString();
                    goto case 0;
                case 0:
                    this.m_Action = reader.ReadString();
                    break;
            }
        }
开发者ID:jasegiffin,项目名称:JustUO,代码行数:15,代码来源:XmlDeathAction.cs

示例10: Deserialize

        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadEncodedInt();
            m_ForumAccount = reader.ReadString();
        }
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:7,代码来源:Talisman.cs

示例11: ReadType

        public static Type ReadType(Type[] referenceTable, GenericReader reader)
        {
            int encoding = reader.ReadEncodedInt();

            switch ( encoding )
            {
                default:
                case 0x00: // null
                    {
                        return null;
                    }
                case 0x01: // indexed
                    {
                        int index = reader.ReadEncodedInt();

                        if (index >= 0 && index < referenceTable.Length)
                            return referenceTable[index];

                        return null;
                    }
                case 0x02: // by name
                    {
                        string fullName = reader.ReadString();

                        if (fullName == null)
                            return null;

                        return ScriptCompiler.FindTypeByFullName(fullName, false);
                    }
            }
        }
开发者ID:Crome696,项目名称:ServUO,代码行数:31,代码来源:QuestSerializer.cs

示例12: Deserialize

		public void Deserialize( GenericReader reader )
		{
			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				{
					m_Flag = reader.ReadItem() as IGameFlag;
					goto case 0;
				}
				case 0:
				{
					m_Members = reader.ReadMobileList();
					m_Home = reader.ReadPoint3D();
					m_FlagHome = reader.ReadPoint3D();
					m_Map = reader.ReadMap();
					m_Points = reader.ReadInt();
					m_Name = reader.ReadString();
					m_Hue = reader.ReadInt();
					m_UId = reader.ReadInt();
					m_Game = reader.ReadItem() as CTFGame;
					break;
				}
			}
		}
开发者ID:FreeReign,项目名称:realmofdarkness,代码行数:26,代码来源:CTFTeam.cs

示例13: Deserialize

        public void Deserialize(GenericReader reader)
        {
            int version = reader.ReadInt();

            int count = reader.ReadInt();
            for (int i = 0; i < count; i++)
            {
                ExchangeTypeInfo etinfo = null;

                string fullname = reader.ReadString();
                Type type = ScriptCompiler.FindTypeByFullName(fullname);
                foreach (ExchangeTypeInfo eti in InfoList)
                {
                    if (eti.Type == type)
                    {
                        etinfo = eti;
                        break;
                    }
                }

                if (etinfo == null)
                    etinfo = new ExchangeTypeInfo(typeof(Gold), "readerror");

                etinfo.Deserialize(reader);
                etinfo.Category = this;
            }
        }
开发者ID:kamronbatman,项目名称:Defiance-AOS-Pre-2012,代码行数:27,代码来源:ExchangeCategory.cs

示例14: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				case 0:
				{
					m_MultiID = reader.ReadInt();
					m_Offset = reader.ReadPoint3D();
					m_ShipName = reader.ReadString();

					if ( version == 0 )
						reader.ReadUInt();

					break;
				}
			}

			if ( LootType == LootType.Newbied )
				LootType = LootType.Blessed;

			if ( Weight == 0.0 )
				Weight = 1.0;
		}
开发者ID:greeduomacro,项目名称:last-wish,代码行数:28,代码来源:BaseDockedBoat.cs

示例15: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();

            switch ( version )
            {
                case 2: // Reset from Resource System
                    this.m_Resource = this.DefaultResource;
                    reader.ReadString();
                    break;
                case 1:
                    {
                        this.m_Resource = (CraftResource)reader.ReadInt();
                        break;
                    }
                case 0:
                    {
                        OreInfo info;

                        switch ( reader.ReadInt() )
                        {
                            case 0:
                                info = OreInfo.Iron;
                                break;
                            case 1:
                                info = OreInfo.DullCopper;
                                break;
                            case 2:
                                info = OreInfo.ShadowIron;
                                break;
                            case 3:
                                info = OreInfo.Copper;
                                break;
                            case 4:
                                info = OreInfo.Bronze;
                                break;
                            case 5:
                                info = OreInfo.Gold;
                                break;
                            case 6:
                                info = OreInfo.Agapite;
                                break;
                            case 7:
                                info = OreInfo.Verite;
                                break;
                            case 8:
                                info = OreInfo.Valorite;
                                break;
                            default:
                                info = null;
                                break;
                        }

                        this.m_Resource = CraftResources.GetFromOreInfo(info);
                        break;
                    }
            }
        }
开发者ID:Ziden,项目名称:ServUO-EC-Test-Fork,代码行数:60,代码来源:Ore.cs


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