예제 #1
0
 public WFVertexWrapper(IGraphWrapper graphWrapper,IVertex vertex)
 {
     this.graphWrapper = graphWrapper;
     vertexValue = vertex.Value;
     if ( graphWrapper.Graph != vertex.Graph )
         throw new Exception( "Invalid argument - vertex or graphWrapper. Method - WFVertexWrapper.constructor(IGraphWrapper,IVertex)" );
 }
 public MyFitnessPalXMLWrapper(string ConfigFileName, int Days, IGraphWrapper graphWrapper)
 {
     config = new LoadConfig(ConfigFileName);
     loginDetails = (LoginDetails)config.GetContents(typeof(LoginDetails));
     cookieDetails = (CookieDetails)config.BinaryDeserialize(typeof(CookieDetails));
     login = new Login(loginDetails, cookieDetails);
     Loader = new XMLMyFitnessLoader(login);
     MyFitnesses = new MyFitnessList();
     this.graphWrapper = graphWrapper;
     this.Days = Days;
 }
        public override void CopyTo(IGraphWrapper graphWrapper)
        {
            base.CopyTo(graphWrapper);

            (graphWrapper as PetriNetGraphWrapper).DefaultPlaceSize = this.DefaultPlaceSize;
            (graphWrapper as PetriNetGraphWrapper).DefaultTransitionSize = this.DefaultTransitionSize;
            (graphWrapper as ColouredPetriGraphWrapper).ColorsDescription = new List<Tuple<string, string, string>>(this.ColorsDescription);
            (graphWrapper as ColouredPetriGraphWrapper).VariablesDescription = new List<Tuple<string, string>>(this.VariablesDescription);
            (graphWrapper as ColouredPetriGraphWrapper).FunctionsDescription = new List<string>(this.FunctionsDescription);

            ColouredPetriGraphWrapper.SetDefaultEventHandlers(graphWrapper as ColouredPetriGraphWrapper);
        }
예제 #4
0
        public WFArcWrapper(IGraphWrapper graphWrapper, IEdge edge)
        {
            if(edge.Graph != graphWrapper.Graph)
                throw new Exception("Invalid argument - edge or graphWrapper. Method - WFArcWrapper.constructor(IGraphWrapper,IEdge)");

            this.SelectedPointWidth = 10;

            this.graphWrapper = graphWrapper;

            this.vertices = edge.Vertices;

            this.splinePointsIndexes = new List<int>();
        }
 public override void CopyTo(IGraphWrapper graphWrapper)
 {
     base.CopyTo(graphWrapper);
     SemanticGraphWrapper.SetDefaultEventHandlers(graphWrapper as SemanticGraphWrapper);
 }
예제 #6
0
 public TransitionWrapper(IGraphWrapper graphWrapper, Transition transition)
     : base(graphWrapper, transition)
 {
 }
 public ColouredPlaceWrapper(IGraphWrapper graphWrapper, ColouredPlace place)
     : base(graphWrapper, place)
 {
 }
예제 #8
0
 public MarkedPlaceWrapper(IGraphWrapper graphWrapper, MarkedPlace markedPlace)
     : base(graphWrapper, markedPlace)
 {
     TokenSize = new Size(5, 5);
 }
예제 #9
0
        public virtual void CopyTo(IGraphWrapper graphWrapper)
        {
            graphWrapper.ArcWrappers = new List<IArcWrapper>(this.ArcWrappers);
            graphWrapper.VertexWrappers = new List<IVertexWrapper>(this.VertexWrappers);

            this.Graph.CopyTo(graphWrapper.Graph);

            graphWrapper.VertexWrappers.ForEach(v => v.graphWrapper = graphWrapper);

            foreach (var arcWrapper in graphWrapper.ArcWrappers)
            {
                arcWrapper.Edge = graphWrapper.Graph[arcWrapper.Edge.Vertices[0].Value, arcWrapper.Edge.Vertices[1].Value];
                arcWrapper.graphWrapper = graphWrapper;
            }

            (graphWrapper as WFGraphWrapper).counter = this.counter;
            (graphWrapper as WFGraphWrapper).DefaultVertexSize = new Size(this.DefaultVertexSize.Width, this.DefaultVertexSize.Height);

            WFGraphWrapper.SetDefaultEventHandlers(graphWrapper as WFGraphWrapper);
        }
예제 #10
0
 public PlaceWrapper(IGraphWrapper graphWrapper, Place place)
     : base(graphWrapper, place)
 {
 }
예제 #11
0
 public NamedArcWrapper(IGraphWrapper graphWrapper, NamedArc arc)
     : base(graphWrapper, arc)
 {
 }
예제 #12
0
        public override void CopyTo(IGraphWrapper graphWrapper)
        {
            base.CopyTo(graphWrapper);

            (graphWrapper as PetriNetGraphWrapper).DefaultPlaceSize = this.DefaultPlaceSize;
            (graphWrapper as PetriNetGraphWrapper).DefaultTransitionSize = this.DefaultTransitionSize;

            PetriNetGraphWrapper.SetDefaultEventHandlers(graphWrapper as PetriNetGraphWrapper);
        }
        public override void CopyTo(IGraphWrapper graphWrapper)
        {
            base.CopyTo(graphWrapper);

            MarkedPetriGraphWrapper.SetDefaultEventHandlers(graphWrapper as MarkedPetriGraphWrapper);
        }