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


C# AssetType类代码示例

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


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

示例1: ReceiveAndUse

 private void ReceiveAndUse(UUID objectid, AssetType type)
 {
     if (type==AssetType.Clothing)
     {
         Received.Add(objectid);
     }
 }
开发者ID:drzo,项目名称:opensim4opencog,代码行数:7,代码来源:FashionBotModuleMain.cs

示例2: AssetKey

 public AssetKey(AssetType assetType, params string[] tags)
 {
     AssetType = assetType;
     Tags = tags.Select(x => x.ToUpperInvariant()).OrderBy(x => x).ToArray();
     var objects = Tags.Concat(new string[] { AssetType.ToString() }).ToArray();
     compoundKey = new CompoundKey(objects);
 }
开发者ID:chriskooken,项目名称:Pithy,代码行数:7,代码来源:AssetKey.cs

示例3: AssetsGroup

        public AssetsGroup( AssetType assetType )
        {
            InitializeComponent( );

            _assets = new AssetsPool( );
            _assetType = assetType;
        }
开发者ID:HaKDMoDz,项目名称:Lunar-Development-Kit,代码行数:7,代码来源:AssetsGroup.cs

示例4: CheckContainsReferences

 private void CheckContainsReferences(AssetType assetType, bool expected)
 {
     AssetBase asset = new AssetBase();
     asset.Type = (sbyte)assetType;
     bool actual = asset.ContainsReferences;
     Assert.AreEqual(expected, actual, "Expected "+assetType+".ContainsReferences to be "+expected+" but was "+actual+".");
 }
开发者ID:ChrisD,项目名称:opensim,代码行数:7,代码来源:AssetBaseTest.cs

示例5: GatherAssetUuids

        /// <summary>
        ///     Gather all the asset uuids associated with the asset referenced by a given uuid
        /// </summary>
        /// This includes both those directly associated with
        /// it (e.g. face textures) and recursively, those of items within it's inventory (e.g. objects contained
        /// within this object).
        /// <param name="assetUuid">The uuid of the asset for which to gather referenced assets</param>
        /// <param name="assetType">The type of the asset for the uuid given</param>
        /// <param name="assetUuids">The assets gathered</param>
        /// <param name="scene"></param>
        public void GatherAssetUuids(UUID assetUuid, AssetType assetType, IDictionary<UUID, AssetType> assetUuids,
                                     IRegistryCore scene)
        {
            // avoid infinite loops
            if (assetUuids.ContainsKey(assetUuid))
                return;

            assetUuids[assetUuid] = assetType;

            switch (assetType)
            {
                case AssetType.Clothing:
                case AssetType.Bodypart:
                    GetWearableAssetUuids(assetUuid, assetUuids);
                    break;
                case AssetType.Gesture:
                    GetGestureAssetUuids(assetUuid, assetUuids);
                    break;
                case AssetType.LSLText:
                    GetScriptAssetUuids(assetUuid, assetUuids);
                    break;
                case AssetType.Object:
                    GetSceneObjectAssetUuids(assetUuid, assetUuids, scene);
                    break;
            }
        }
开发者ID:velus,项目名称:Async-Sim-Testing,代码行数:36,代码来源:UuidGatherer.cs

示例6: StoreData

        public void StoreData(AssetType type, string path, IAssetCachedData metadata)
        {
            var metaDataPath = GetCachedDataFilePath(type, path);

            var data = JsonConvert.SerializeObject(metadata);
            File.WriteAllText(metaDataPath, data);
        }
开发者ID:ParkitectNexus,项目名称:ParkitectNexusClient,代码行数:7,代码来源:AssetCachedDataStorage.cs

示例7: MissingItemInfo

 public MissingItemInfo(MemberInfo name,UUID id)
 {
     MemberName = name;
     MissingID = id;
     key = MemberName.DeclaringType.Name + "." + MemberName.Name + "=" + MissingID;
     AssetType = GuessType(name);
 }
开发者ID:drzo,项目名称:opensim4opencog,代码行数:7,代码来源:ImportCommand_Assets.cs

示例8: CreateBundles

 private List<string> CreateBundles(FileListsByAssetType fileListsByAssetType, AssetType assetType, Func<string, string[], Bundle> bundleFactory)
 {
     List<AssetPath> files = fileListsByAssetType.GetList(assetType);
     List<List<AssetPath>> filesByAreaController = RouteHelper.FilePathsSortedByRoute(files);
     List<string> bundleVirtualPaths = BundleHelper.AddFileListsAsBundles(_bundles, filesByAreaController, bundleFactory);
     return bundleVirtualPaths;
 }
开发者ID:nbucket,项目名称:dynamicbundles,代码行数:7,代码来源:DynamicBundlesBuilder.cs

示例9: pb_MetaData

		/**
		 * Serialized constructor.
		 */
		public pb_MetaData(SerializationInfo info, StreamingContext context)
		{
			_fileId				= (string) info.GetValue("_fileId", typeof(string));
			_assetBundlePath	= (pb_AssetBundlePath) info.GetValue("_assetBundlePath", typeof(pb_AssetBundlePath));
			_assetType			= (AssetType) info.GetValue("_assetType", typeof(AssetType));
			componentDiff		= (pb_ComponentDiff) info.GetValue(	"componentDiff", typeof(pb_ComponentDiff));
		}
开发者ID:procore3d,项目名称:giles,代码行数:10,代码来源:pb_MetaData.cs

示例10: Asset

            public Asset(string text, AssetType type)
            {
                if (text == null) throw new ArgumentNullException("text");

                Text = text;
                Type = type;
            }
开发者ID:ronnieoverby,项目名称:MvcAssetManager,代码行数:7,代码来源:AssetManager.cs

示例11: AssetRequirement

 public AssetRequirement(AssetType type, string file, string inline = null, string addOnceToken = null)
 {
     Type = type;
     File = file;
     Inline = inline;
     AddOnceToken = addOnceToken;
 }
开发者ID:BIGANDYT,项目名称:spitfire-vitality,代码行数:7,代码来源:AssetRequirement.cs

示例12: MultiRelationAttributeDefinition

 public MultiRelationAttributeDefinition(Type type, PropertyInfo property, Type relatedType, AssetType assetType, AssetType relatedAssetType)
     : base(assetType, property.Name, false, relatedAssetType, true)
 {
     _type = type;
     _property = property;
     _relatedType = relatedType;
 }
开发者ID:donald-hanson,项目名称:V1Antlr,代码行数:7,代码来源:MultiRelationAttributeDefinition.cs

示例13: GatherAssetUuids

        /// <summary>
        ///   Gather all the asset uuids associated with the asset referenced by a given uuid
        /// </summary>
        /// This includes both those directly associated with
        /// it (e.g. face textures) and recursively, those of items within it's inventory (e.g. objects contained
        /// within this object).
        /// <param name = "assetUuid">The uuid of the asset for which to gather referenced assets</param>
        /// <param name = "assetType">The type of the asset for the uuid given</param>
        /// <param name = "assetUuids">The assets gathered</param>
        public void GatherAssetUuids(UUID assetUuid, AssetType assetType, IDictionary<UUID, AssetType> assetUuids,
                                     IRegistryCore scene)
        {
            // avoid infinite loops
            if (assetUuids.ContainsKey(assetUuid))
                return;

            assetUuids[assetUuid] = assetType;

            if (AssetType.Bodypart == assetType || AssetType.Clothing == assetType)
            {
                GetWearableAssetUuids(assetUuid, assetUuids);
            }
            else if (AssetType.Gesture == assetType)
            {
                GetGestureAssetUuids(assetUuid, assetUuids);
            }
            else if (AssetType.LSLText == assetType)
            {
                GetScriptAssetUuids(assetUuid, assetUuids);
            }
            else if (AssetType.Object == assetType)
            {
                GetSceneObjectAssetUuids(assetUuid, assetUuids, scene);
            }
        }
开发者ID:nathanmarck,项目名称:Aurora-Sim,代码行数:35,代码来源:UuidGatherer.cs

示例14: GetImage

 public Image GetImage(AssetType type)
 {
     return new Image()
     {
         Source =  this.LoadImage(type)
     };
 }
开发者ID:ivailojordanov,项目名称:Fundamental-Level,代码行数:7,代码来源:AssetLoader.cs

示例15: GetFilesInAssetPath

        private string[] GetFilesInAssetPath(AssetType type)
        {
            switch (type)
            {
                case AssetType.Blueprint:
                    if (_parkitect.Paths.GetAssetPath(type) == null)
                        return new string[0];

                    return Directory.GetFiles(_parkitect.Paths.GetAssetPath(type), "*.png",
                        SearchOption.AllDirectories);
                case AssetType.Savegame:
                    if (_parkitect.Paths.GetAssetPath(type) == null)
                        return new string[0];

                    return Directory.GetFiles(_parkitect.Paths.GetAssetPath(type), "*.txt",
                        SearchOption.AllDirectories)
                        .Concat(Directory.GetFiles(_parkitect.Paths.GetAssetPath(type), "*.park",
                            SearchOption.AllDirectories)).ToArray();
                case AssetType.Mod:
                    if (_parkitect.Paths.GetAssetPath(type) == null)
                        return new string[0];
                    return Directory.GetDirectories(_parkitect.Paths.GetAssetPath(AssetType.Mod))
                        .Where(path => File.Exists(Path.Combine(path, "mod.json")))
                        .ToArray();
                default:
                    throw new Exception("unsupported asset type.");
            }
        }
开发者ID:ParkitectNexus,项目名称:ParkitectNexusClient,代码行数:28,代码来源:LocalAssetRepository.cs


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