Beispiel #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="mountDAO"></param>
        /// <returns></returns>
        public MountEntity CreateMount(MountDAO mountDAO)
        {
            var mount = new MountEntity(mountDAO);

            m_mountById.Add(mount.UniqueId, mount);
            return(mount);
        }
Beispiel #2
0
        public static MountModel Create(string path, MountContext context, MountEntity entity)
        {
            var get        = Get(path);
            var mntContext = get?.MountContext ?? context;
            var exMount    = Get(path);

            if (exMount != null)
            {
                return(exMount);
            }
            var mount = new MountModel {
                _Id          = Guid.NewGuid().ToString(),
                Guid         = Guid.NewGuid().ToString(),
                DFPTimestamp = Timestamp.Now,
                MountContext = mntContext,
                MountEntity  = entity,
                Path         = path
            };

            DeNSo.Session.New.Set(mount);
            return(mount);
        }