예제 #1
0
        private static string GetShapeCustomType(Visio.Shape shape)
        {
            string UmlElementType = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            var    type           = "";

            if (UmlElementType.Equals("Start"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }
            else if (UmlElementType.Equals("End"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }
            else if (UmlElementType.Equals("Rel"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }
            else if (UmlElementType.Equals("Action"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }
            else if (UmlElementType.Equals("ParallelGateway"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }
            else if (UmlElementType.Equals("InclusiveGateway"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }
            else if (UmlElementType.Equals("ExclusiveGateway"))
            {
                type = VisioHelper.ReadANamedCustomProperty(shape, "Type", false);
            }

            return(type);
        }
예제 #2
0
        private static double GetShapeTime(Shape shape)
        {
            string customPropertyTime = VisioHelper.ReadANamedCustomProperty(shape, "Time", false);

            return(customPropertyTime != "" ? Double.Parse(customPropertyTime) : 0);
        }