public static AssetDetailConfig CreateAssetDetailConfig(PackerData packerData)
        {
            List <AssetDetail> details = new List <AssetDetail>();

            foreach (var group in packerData.groupDatas)
            {
                foreach (var bundle in group.bundleDatas)
                {
                    foreach (var asset in bundle.assetDatas)
                    {
                        if (asset.IsMainAsset)
                        {
                            AssetDetail detail = new AssetDetail()
                            {
                                Address = asset.Address,
                                Path    = asset.Path,
                                Bundle  = bundle.Path,
                                IsScene = asset.IsScene,
                                Labels  = asset.Labels,
                            };
                            details.Add(detail);
                        }
                    }
                }
            }

            AssetDetailConfig detailConfig = new AssetDetailConfig();

            detailConfig.Details = details.ToArray();
            return(detailConfig);
        }
        public IActionResult DeleteConfirmed(long id)
        {
            AssetDetail assetDetail = service.FindById(id);

            service.Remove(id);
            return(RedirectToAction("Edit", "Asset", new { id = assetDetail.AssetID }));
        }
Esempio n. 3
0
 public AssetReservationRow(AssetDetail asset)
 {
     AssetId      = asset.AssetId;
     Description  = asset.Description ?? "<No information available.>";
     Availability = GetDescription(asset.Availability).FormatWith(asset.AvailabilityEndTime.ToString());
     Icon         = IconList.Images[asset.Availability.ToString()];
 }
        public IActionResult Edit(long id, [Bind("AssetDetailID,AssetID,DetailID,Definition1,Definition2")] AssetDetail assetDetail)
        {
            if (id != assetDetail.AssetDetailID)
            {
                return(NotFound());
            }

            if (ModelState.IsValid)
            {
                try
                {
                    service.Update(assetDetail);
                }
                catch (DbUpdateConcurrencyException)
                {
                    if (!AssetDetailExists(assetDetail.AssetDetailID))
                    {
                        return(NotFound());
                    }
                    else
                    {
                        throw;
                    }
                }
                return(RedirectToAction("Edit", "Asset", new { id = assetDetail.AssetID }));
            }
            //ViewData["DetailID"] = new List<SelectListItem>(service.GetSelectListDetails());
            ViewData["DetailID"] = new List <SelectListItem>(service.GetSelectListDetailsOfProductType(assetDetail.AssetID));
            return(View(assetDetail));
        }
Esempio n. 5
0
        private void assetView_EditEvent(object sender, EventArgs e)
        {
            AssetDetail view = new AssetDetail(GlobalService.AssetId);

            view.SavedEvent  += new EventHandler(view_SavedEvent);
            view.CancelEvent += new EventHandler(view_CancelEvent);
            LoadControl(view);
        }
 public IActionResult Create(long assetID, [Bind("AssetDetailID,AssetID,DetailID,Definition1,Definition2")] AssetDetail assetDetail)
 {
     if (ModelState.IsValid)
     {
         service.Add(assetDetail);
         return(RedirectToAction("Edit", "Asset", new { id = assetID }));
     }
     ViewData["AssetID"]  = assetID;
     ViewData["DetailID"] = new List <SelectListItem>(service.GetSelectListDetails());
     return(View(assetDetail));
 }
        // GET: AssetDetail/Details/
        public IActionResult Details(long?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            AssetDetail assetDetail = service.FindById(id.Value);

            if (assetDetail == null)
            {
                return(NotFound());
            }

            return(View(assetDetail));
        }
        public IActionResult Edit(long?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            AssetDetail assetDetail = service.FindById(id.Value);

            if (assetDetail == null)
            {
                return(NotFound());
            }
            //ViewData["DetailID"] = new List<SelectListItem>(service.GetSelectListDetails());
            ViewData["DetailID"] = new List <SelectListItem>(service.GetSelectListDetailsOfProductType(id.Value));
            return(View(assetDetail));
        }
Esempio n. 9
0
        /// <summary>
        /// adc is the active list. Returns true if the AssetDetail is already in the list. Will
        /// check to see if the asset detail is active or not. If not active in list and the given is active,
        /// will reset the list.
        /// </summary>
        /// <param name="adc">AssetDetailCollection</param>
        /// <param name="ad">AssetDetail</param>
        /// <returns>bool</returns>
        private bool FoundAssetDetail(AssetDetailCollection adc, AssetDetail ad)
        {
            bool bFound = false;

            foreach (AssetDetail item in adc)
            {
                if (item.AssetId.Equals(ad.AssetId))
                {
                    bFound = true;
                    if (!AssetAvailable(item) && AssetAvailable(ad))
                    {
                        // ID's and descriptions are the same so just reset the availability information for the device in the primary list.
                        item.Availability          = ad.Availability;
                        item.AvailabilityStartTime = ad.AvailabilityStartTime;
                        item.AvailabilityEndTime   = ad.AvailabilityEndTime;

                        break;
                    }
                }
            }

            return(bFound);
        }
Esempio n. 10
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AssetHost" /> class.
 /// </summary>
 /// <param name="asset">The asset data.</param>
 /// <param name="name">The name of this host.</param>
 /// <param name="type">The type of status element.</param>
 /// <param name="subtype">The subtype.</param>
 public AssetHost(AssetDetail asset, string name, ElementType type, string subtype)
 {
     Asset                = asset;
     MapElement           = new SessionMapElement(name, type, subtype);
     AssetMemoryRetrieved = DateTime.Now.AddDays(-1);
 }
Esempio n. 11
0
 /// <summary>
 /// Badge Box Host
 /// </summary>
 /// <param name="asset"></param>
 public BadgeBoxHost(AssetDetail asset)
     : base(asset, asset.AssetId, ElementType.BadgeBox, "BadgeBox")
 {
     _badgeBox = asset as BadgeBoxDetail;
 }
Esempio n. 12
0
        public List <AssetDetail> AssetDetail(int id)
        {
            AssetDetail         ad  = new AssetDetail();
            List <AssetDetail>  lad = new List <AssetDetail>();
            SqlParameter        pt  = new SqlParameter();
            List <SqlParameter> lpt = new List <SqlParameter>();

            //var query = "SELECT ats.Asset_ID,ats.Asset_Name,ats.Asset_Serial,ap.Type_Name,ap.Type_Detail,ats.Asset_Datebuy,ats.Asset_Waranty,ats.Asset_Price,ats.Asset_Supply," +
            //            "us.User_Fristname + ' ' + us.User_Lastname AS USERS, ad.User_Fristname + ' ' + ad.User_Lastname AS ADMINS, ats.Asset_Number,ats.Asset_Modify FROM tb_asset AS ats " +
            //            "INNER JOIN tb_users AS us ON ats.User_ID = us.User_ID " +
            //            "INNER JOIN tb_users AS ad ON ats.Admin_ID = ad.User_ID " +
            //            "INNER JOIN tb_as_type AS ap ON ats.Type_ID = ap.Type_ID" +
            //            "WHERE ats.Asset_ID = @Asset_ID";

            var query = "SELECT Asset_ID,Asset_Name,Asset_Serial,Type_Name,Type_Detail,Asset_Datebuy,Asset_Waranty,Asset_Price,Asset_Supply," +
                        "us.User_Fristname + ' ' + us.User_Lastname AS USERS, ad.User_Fristname + ' ' + ad.User_Lastname AS ADMINS, Asset_Number, Asset_Modify FROM tb_asset AS ats " +
                        "INNER JOIN tb_users AS us ON ats.User_ID = us.User_ID " +
                        "INNER JOIN tb_users AS ad ON ats.Admin_ID = ad.User_ID " +
                        "INNER JOIN tb_as_type AS ap ON ats.Type_ID = ap.Type_ID ";

            pt = new SqlParameter();
            pt.ParameterName = "@Asset_ID";
            pt.Value         = id;
            lpt.Add(pt);

            SqlConnection con = new SqlConnection(Startup.ConnectionString);
            SqlCommand    cmd = new SqlCommand(query, con);

            foreach (var item in lpt)
            {
                cmd.Parameters.Add(item);
            }
            con.Open();
            SqlDataReader reder = cmd.ExecuteReader();

            //while (reder.Read())
            //{
            //    ad = new AssetDetail();
            //    if (reder["ats.Asset_ID"] != DBNull.Value)
            //    {
            //        ad.Asset_ID = int.Parse(reder["ats.Asset_ID"].ToString());
            //    }
            //    if (reder["ats.Asset_Name"] != DBNull.Value)
            //    {
            //        ad.Asset_Name = reder["ats.Asset_Name"].ToString();
            //    }
            //    if (reder["ats.Asset_Serial"] != DBNull.Value)
            //    {
            //        ad.Asset_Serail = reder["ats.Asset_Serial"].ToString();
            //    }
            //    if (reder["ap.Type_Name"] != DBNull.Value)
            //    {
            //        ad.Type_Name = reder["ap.Type_Name"].ToString();
            //    }
            //    if (reder["ap.Type_Detail"] != DBNull.Value)
            //    {
            //        ad.Type_Detail = reder["ap.Type_Detail"].ToString();
            //    }
            //    if (reder["ats.Asset_Datebuy"] != DBNull.Value)
            //    {
            //        ad.Asset_Detebuy = reder["ast.Asset_Datebuy"].ToString();
            //    }
            //    if (reder["ats.Asset_Waranty"] != DBNull.Value)
            //    {
            //        ad.Asset_Waranty = reder["ats.Asset_Waranty"].ToString();
            //    }
            //    if (reder["ats.Asset_Price"] != DBNull.Value)
            //    {
            //        ad.Asset_Price = reder["ats.Asset_Price"].ToString();
            //    }
            //    if (reder["ast.Asset_Supply"] != DBNull.Value)
            //    {
            //        ad.Asset_Supply = reder["ast.Asset_Supply"].ToString();
            //    }
            //    if (reder["USERS"] != DBNull.Value)
            //    {
            //        ad.USERS = reder["USERS"].ToString();
            //    }
            //    if (reder["ADMINS"] != DBNull.Value)
            //    {
            //        ad.ADMINS = reder["ADMINS"].ToString();
            //    }
            //    if (reder["ats.Asset_Number"] != DBNull.Value)
            //    {
            //        ad.Asset_Number = reder["ats.Asset_Number"].ToString();
            //    }
            //    if (reder["ats.Asset_Modify"] != DBNull.Value)
            //    {
            //        ad.Asset_Modify = reder["ats.Asset_Modify"].ToString();
            //    }
            //    lad.Add(ad);
            //}
            while (reder.Read())
            {
                ad = new AssetDetail();
                if (reder["Asset_ID"] != DBNull.Value)
                {
                    ad.Asset_ID = int.Parse(reder["Asset_ID"].ToString());
                }
                if (reder["Asset_Name"] != DBNull.Value)
                {
                    ad.Asset_Name = reder["Asset_Name"].ToString();
                }
                if (reder["Asset_Serial"] != DBNull.Value)
                {
                    ad.Asset_Serail = reder["Asset_Serial"].ToString();
                }
                if (reder["Type_Name"] != DBNull.Value)
                {
                    ad.Type_Name = reder["Type_Name"].ToString();
                }
                if (reder["Type_Detail"] != DBNull.Value)
                {
                    ad.Type_Detail = reder["Type_Detail"].ToString();
                }
                if (reder["Asset_Datebuy"] != DBNull.Value)
                {
                    ad.Asset_Detebuy = reder["Asset_Datebuy"].ToString();
                }
                if (reder["Asset_Waranty"] != DBNull.Value)
                {
                    ad.Asset_Waranty = reder["Asset_Waranty"].ToString();
                }
                if (reder["Asset_Price"] != DBNull.Value)
                {
                    ad.Asset_Price = reder["Asset_Price"].ToString();
                }
                if (reder["Asset_Supply"] != DBNull.Value)
                {
                    ad.Asset_Supply = reder["Asset_Supply"].ToString();
                }
                if (reder["USERS"] != DBNull.Value)
                {
                    ad.USERS = reder["USERS"].ToString();
                }
                if (reder["ADMINS"] != DBNull.Value)
                {
                    ad.ADMINS = reder["ADMINS"].ToString();
                }
                if (reder["Asset_Number"] != DBNull.Value)
                {
                    ad.Asset_Number = reder["Asset_Number"].ToString();
                }
                if (reder["Asset_Modify"] != DBNull.Value)
                {
                    ad.Asset_Modify = reder["Asset_Modify"].ToString();
                }
                lad.Add(ad);
            }
            return(lad);
        }
Esempio n. 13
0
 public void Add(AssetDetail assetDetail)
 {
     repository.Add(assetDetail);
 }
Esempio n. 14
0
 public void Update(AssetDetail assetDetail)
 {
     repository.Update(assetDetail);
 }
Esempio n. 15
0
        void FindAssets()
        {
            objList.Clear();
            if (mode == FA_MODE)
            {
                if (assetType == MATERIALS)
                {
                    foreach (Renderer renderer in FindObjects <Renderer>())
                    {
                        if (ignoreInactive && !renderer.gameObject.activeInHierarchy)
                        {
                            continue;
                        }
                        foreach (Material material in renderer.sharedMaterials)
                        {
                            if (material == null || !material.shader.name.StartsWith(shaderName))
                            {
                                continue;
                            }
                            if (!objList.Contains(material) && Filter(material))
                            {
                                objList.Add(material);
                            }
                        }
                    }

                    type = typeof(Material);
                }
                else if (assetType == TEXTURES)
                {
                    foreach (Renderer renderer in FindObjects <Renderer>())
                    {
                        if (ignoreInactive && !renderer.gameObject.activeInHierarchy)
                        {
                            continue;
                        }
                        foreach (Material material in renderer.sharedMaterials)
                        {
                            if (material != null)
                            {
                                Shader s = material.shader;
                                if (!s.name.StartsWith(shaderName))
                                {
                                    continue;
                                }
                                int propCount = ShaderUtil.GetPropertyCount(s);
                                for (int i = 0; i < propCount; i++)
                                {
                                    if (ShaderUtil.GetPropertyType(s, i) == ShaderUtil.ShaderPropertyType.TexEnv)
                                    {
                                        string propName = ShaderUtil.GetPropertyName(s, i);
                                        if ((materialPropertyName.Equals("") || materialPropertyName.Equals(propName)) && material.HasProperty(propName))
                                        {
                                            Texture texture = material.GetTexture(propName);
                                            if (texture != null && !objList.Contains(texture) && Filter(texture))
                                            {
                                                objList.Add(texture);
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }

                    type = typeof(Texture);
                }
                else if (assetType == MESHES)
                {
                    if (searchMeshFilters)
                    {
                        foreach (MeshFilter mf in FindObjects <MeshFilter>())
                        {
                            if (ignoreInactive && !mf.gameObject.activeInHierarchy)
                            {
                                continue;
                            }
                            Mesh mesh = mf.sharedMesh;
                            if (mesh != null && !objList.Contains(mesh) && Filter(mesh))
                            {
                                objList.Add(mesh);
                            }
                        }
                    }
                    if (searchSkinnedMeshRenderers)
                    {
                        foreach (SkinnedMeshRenderer smr in FindObjects <SkinnedMeshRenderer>())
                        {
                            if (ignoreInactive && !smr.gameObject.activeInHierarchy)
                            {
                                continue;
                            }
                            Mesh mesh = smr.sharedMesh;
                            if (mesh != null && !objList.Contains(mesh) && Filter(mesh))
                            {
                                objList.Add(mesh);
                            }
                        }
                    }
                    if (searchMeshColliders)
                    {
                        foreach (MeshCollider mc in FindObjects <MeshCollider>())
                        {
                            if (ignoreInactive && !mc.gameObject.activeInHierarchy)
                            {
                                continue;
                            }
                            Mesh mesh = mc.sharedMesh;
                            if (mesh != null && !objList.Contains(mesh) && Filter(mesh))
                            {
                                objList.Add(mesh);
                            }
                        }
                    }

                    type = typeof(Mesh);
                }
                else if (assetType == AUDIO_CLIPS)
                {
                    foreach (AudioSource audioSource in FindObjects <AudioSource>())
                    {
                        if (ignoreInactive && !audioSource.gameObject.activeInHierarchy)
                        {
                            continue;
                        }
                        AudioClip audio = audioSource.clip;
                        if (audio != null && !objList.Contains(audio) && Filter(audio))
                        {
                            objList.Add(audio);
                        }
                    }

                    type = typeof(AudioClip);
                }
                else if (assetType == ANIMATION_CLIPS)
                {
                    foreach (Animator animator in FindObjects <Animator>())
                    {
                        if (ignoreInactive && !animator.gameObject.activeInHierarchy)
                        {
                            continue;
                        }
                        if (animator.runtimeAnimatorController == null)
                        {
                            continue;
                        }
                        foreach (AnimationClip anim in animator.runtimeAnimatorController.animationClips)
                        {
                            if (anim != null && !objList.Contains(anim) && Filter(anim))
                            {
                                objList.Add(anim);
                            }
                        }
                    }
//					foreach (Animation animation in FindObjects<Animation>()){
//						if (ignoreInactive && !animation.gameObject.activeInHierarchy) continue;
//						foreach (AnimationState animState in animation){//Updates on PlayMode only
//							AnimationClip anim = animState.clip;//Check null state
//							if (anim!=null && !objList.Contains(anim) && Filter(anim))
//							{
//								objList.Add(anim);
//							}
//						}
//					}
                    type = typeof(AnimationClip);
                }
            }
            else if (mode == FU_MODE)
            {
                if (assetType == MATERIALS)
                {
                    if (filterMaterial != null)
                    {
                        foreach (Renderer renderer in FindObjects <Renderer>())
                        {
                            GameObject go = renderer.gameObject;
                            if (ignoreInactive && !go.activeInHierarchy)
                            {
                                continue;
                            }
                            foreach (Material material in renderer.sharedMaterials)
                            {
                                //if (material == null || !material.shader.name.StartsWith(shaderName)) continue; //Ignore shader filter, it's redundant.
                                if (material == filterMaterial && Filter(go))
                                {
                                    objList.Add(go);
                                    break;
                                }
                            }
                        }
                    }

                    type = typeof(GameObject);
                }
                else if (assetType == TEXTURES)
                {
                    if (filterTexture != null)
                    {
                        foreach (Renderer renderer in FindObjects <Renderer>())
                        {
                            GameObject go = renderer.gameObject;
                            if (ignoreInactive && !go.activeInHierarchy)
                            {
                                continue;
                            }
                            foreach (Material material in renderer.sharedMaterials)
                            {
                                if (material != null)
                                {
                                    Shader s = material.shader;
                                    if (!s.name.StartsWith(shaderName))
                                    {
                                        continue;
                                    }
                                    int propCount = ShaderUtil.GetPropertyCount(s);
                                    for (int i = 0; i < propCount; i++)
                                    {
                                        if (ShaderUtil.GetPropertyType(s, i) == ShaderUtil.ShaderPropertyType.TexEnv)
                                        {
                                            string propName = ShaderUtil.GetPropertyName(s, i);
                                            if ((materialPropertyName.Equals("") || materialPropertyName.Equals(propName)) && material.HasProperty(propName))
                                            {
                                                Texture texture = material.GetTexture(propName);
                                                if (texture == filterTexture && !objList.Contains(go) && Filter(go))
                                                {
                                                    objList.Add(go);
                                                    break;
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }

                    type = typeof(GameObject);
                }
                else if (assetType == MESHES)
                {
                    if (filterMesh != null)
                    {
                        if (searchMeshFilters)
                        {
                            foreach (MeshFilter mf in FindObjects <MeshFilter>())
                            {
                                GameObject go = mf.gameObject;
                                if (ignoreInactive && !go.activeInHierarchy)
                                {
                                    continue;
                                }
                                Mesh mesh = mf.sharedMesh;
                                if (mesh == filterMesh && !objList.Contains(go) && Filter(go))
                                {
                                    objList.Add(go);
                                }
                            }
                        }
                        if (searchSkinnedMeshRenderers)
                        {
                            foreach (SkinnedMeshRenderer smr in FindObjects <SkinnedMeshRenderer>())
                            {
                                GameObject go = smr.gameObject;
                                if (ignoreInactive && !go.activeInHierarchy)
                                {
                                    continue;
                                }
                                Mesh mesh = smr.sharedMesh;
                                if (mesh == filterMesh && !objList.Contains(go) && Filter(go))
                                {
                                    objList.Add(go);
                                }
                            }
                        }
                        if (searchMeshColliders)
                        {
                            foreach (MeshCollider mc in FindObjects <MeshCollider>())
                            {
                                GameObject go = mc.gameObject;
                                if (ignoreInactive && !go.activeInHierarchy)
                                {
                                    continue;
                                }
                                Mesh mesh = mc.sharedMesh;
                                if (mesh == filterMesh && !objList.Contains(go) && Filter(go))
                                {
                                    objList.Add(go);
                                }
                            }
                        }
                    }

                    type = typeof(GameObject);
                }
                else if (assetType == AUDIO_CLIPS)
                {
                    foreach (AudioSource audioSource in FindObjects <AudioSource>())
                    {
                        GameObject go = audioSource.gameObject;
                        if (ignoreInactive && !go.activeInHierarchy)
                        {
                            continue;
                        }
                        AudioClip audio = audioSource.clip;
                        if (audio == filterAudio && !objList.Contains(go) && Filter(go))
                        {
                            objList.Add(go);
                        }
                    }
                    type = typeof(GameObject);
                }
                else if (assetType == ANIMATION_CLIPS)
                {
                    foreach (Animator animator in FindObjects <Animator>())
                    {
                        GameObject go = animator.gameObject;
                        if (ignoreInactive && !go.activeInHierarchy)
                        {
                            continue;
                        }
                        if (animator.runtimeAnimatorController == null)
                        {
                            continue;
                        }
                        foreach (AnimationClip anim in animator.runtimeAnimatorController.animationClips)
                        {
                            if (anim == filterAnim && !objList.Contains(go) && Filter(go))
                            {
                                objList.Add(go);
                            }
                        }
                    }
//					foreach (Animation animation in FindObjects<Animation>())
//					{
//						GameObject go = animation.gameObject;
//						if (ignoreInactive && !go.activeInHierarchy) continue;
//						foreach (AnimationState animState in animation){//Updates in playmode only
//							AnimationClip anim = animState.clip;
//							if (anim == filterAnim && !objList.Contains(go) && Filter(go))
//							{
//								objList.Add(go);
//							}
//						}
//					}
                    type = typeof(GameObject);
                }
            }

            if (sortByName)
            {
                objList.Sort((obj1, obj2) => obj1.name.CompareTo(obj2.name));
            }

            objDetailList = new List <ObjectDetail>(objList.Count);
            foreach (Object obj in objList)
            {
                ObjectDetail detail;
                if (obj is GameObject)
                {
                    detail = ComponentDetail.CreateDetail(obj, this);
                }
                else
                {
                    detail = new AssetDetail(obj);
                }
                objDetailList.Add(detail);
            }

            listIsDirty = false;

            //Fix selection info
            if (firstObjSelected != null && (!objList.Contains(firstObjSelected) ||
                                             !ArrayUtility.Contains <Object>(Selection.objects, firstObjSelected)))
            {
                firstObjSelected = null; lastObjSelected = null;
            }
            if (lastObjSelected != null && (!objList.Contains(lastObjSelected) ||
                                            !ArrayUtility.Contains <Object>(Selection.objects, lastObjSelected)))
            {
                lastObjSelected = firstObjSelected;
            }
            if (firstObjSelected == null || lastObjSelected == null)
            {
                firstObjSelected = objList.Find(obj => ArrayUtility.Contains <Object>(Selection.objects, obj));
                lastObjSelected  = objList.FindLast(obj => ArrayUtility.Contains <Object>(Selection.objects, obj));
            }
        }
 public void Update(AssetDetail assetDetail)
 {
     context.AssetDetails.Update(assetDetail);
     context.SaveChanges();
 }
Esempio n. 17
0
 /// <summary>
 /// Initializes a new instance of the <see cref="JediSimulatorHost"/> class.
 /// </summary>
 /// <param name="asset">The asset details from the manifest.</param>
 public JediSimulatorHost(AssetDetail asset)
     : base(asset, ((JediSimulatorDetail)asset).MachineName, ElementType.Device, "JediSimulator")
 {
     _simulatorDetail = (JediSimulatorDetail)asset;
     _machine         = new ManagedMachine(_simulatorDetail.MachineName, ManagedMachineType.WindowsVirtual);
 }
Esempio n. 18
0
 private bool AssetAvailable(AssetDetail assetDetail)
 {
     return(assetDetail.Availability.Equals(AssetAvailability.Available) || assetDetail.Availability.Equals(AssetAvailability.PartiallyAvailable));
 }
Esempio n. 19
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SiriusSimulatorHost"/> class.
 /// </summary>
 /// <param name="asset">The asset details from the manifest.</param>
 public SiriusSimulatorHost(AssetDetail asset)
     : base(asset, ((SiriusSimulatorDetail)asset).AssetId, ElementType.Device, "SiriusSimulator")
 {
     _simulatorDetail = (SiriusSimulatorDetail)asset;
 }
Esempio n. 20
0
 //private bool _useRecording = true;
 /// <summary>
 ///
 /// </summary>
 /// <param name="asset"></param>
 public CameraHost(AssetDetail asset)
     : base(asset, asset.AssetId, ElementType.Camera, "Camera")
 {
     _cameraDetail = asset as CameraDetail;
 }
Esempio n. 21
0
 /// <summary>
 /// Initializes a new instance of the <see cref="MobileDeviceHost" /> class.
 /// </summary>
 /// <param name="asset">The asset.</param>
 public MobileDeviceHost(AssetDetail asset)
     : base(asset, asset.AssetId, ElementType.Device, "MobileDevice")
 {
 }
 public void Add(AssetDetail assetDetail)
 {
     context.AssetDetails.Add(assetDetail);
     context.SaveChanges();
 }