Ejemplo n.º 1
0
        /// <summary>
        /// Delete this Entry. ThIs operation should succeed, but there are
        /// special circumstances when it will not:
        /// If this Entry Is the root of the Entry tree, it cannot be
        /// deleted, as there Is no way to Create another one.
        /// If this Entry Is a directory, it cannot be deleted unless it Is
        /// empty.
        /// </summary>
        /// <returns>
        /// true if the Entry was successfully deleted, else false
        /// </returns>
        public bool Delete()
        {
            bool rval = false;

            if ((!IsRoot) && IsDeleteOK)
            {
                rval = _parent.DeleteEntry(this);
            }
            return(rval);
        }