Beispiel #1
0
        public override Exceptional Execute(AGraphDSSharp myAGraphDSSharp, ref String myCurrentPath, Dictionary<String, List<AbstractCLIOption>> myOptions, String myInputString)
        {
            if (myAGraphDSSharp == null)
                return new Exceptional(new GraphDSError("myAGraphDSSharp must not be null!"));

            ObjectLocation _DirectoryObjectLocation = null;

            try
            {
                _DirectoryObjectLocation = new ObjectLocation(ObjectLocation.ParseString(myCurrentPath), myOptions.ElementAt(1).Value[0].Option);
            }
            catch (Exception e)
            {
                WriteLine(e.Message);
                return Exceptional.OK;
            }

            try
            {
                myAGraphDSSharp.CreateDirectoryObject(_DirectoryObjectLocation);
            }

            catch (Exception e)
            {
                WriteLine(e.Message);
            }

            return Exceptional.OK;
        }