Esempio n. 1
0
        public Node CreateSubNode(int key)
        {
            if (key < 0)
                throw new RepositoryException("negative key not allowed");

            if (_subNodes == null)
                _subNodes = new SubNodeWithListOfSubNodes(this);

            return _subNodes.CreateSubNode(key);
        }
Esempio n. 2
0
        public Node CreateSubNode(string key)
        {
            if (string.IsNullOrEmpty(key))
                throw new RepositoryException("null string key not allowed");

            if (_subNodes == null)
                _subNodes = new SubNodeWithDictionaryOfSubNodes(this);

            return _subNodes.CreateSubNode(key);
        }