예제 #1
0
        void IFSDirectoryCore.Remove(FSEntry entry)
        {
            if (entry == null)
            {
                throw new ArgumentNullException(nameof(entry));
            }

            children.Remove(entry);
        }
예제 #2
0
        void IFSDirectoryCore.Add(FSEntry entry)
        {
            if (entry == null)
            {
                throw new ArgumentNullException(nameof(entry));
            }
            if (entry.Parent != this)
            {
                throw new ArgumentException(nameof(entry), "Unable to add entry, must have parent set to self");
            }

            children.Add(entry);
        }