Beispiel #1
0
        public Specification(string spec, string option, string filePath) : base(spec, filePath)
        {
            SharedData = new SharedDataObjects();
            PAT.Common.Classes.Ultility.Ultility.LockSharedData(this);

            try
            {
                ParseSpec(spec, option);

                //we need to store the default values that can be used for the simulation.
                SharedData.HasSyncrhonousChannel   = HasSyncrhonousChannel;
                SharedData.SyncrhonousChannelNames = SyncrhonousChannelNames;
                SharedData.HasAtomicEvent          = HasAtomicEvent;
                SharedData.HasCSharpCode           = HasCSharpCode;
                SharedData.LocalVars = Valuation.HiddenVars;
            }
            catch (Exception ex)
            {
                System.Diagnostics.Debug.WriteLine(ex.ToString());
                throw ex;
            }
            finally
            {
                PAT.Common.Classes.Ultility.Ultility.UnLockSharedData(this);
            }
        }
Beispiel #2
0
        //constructor used for the console, testing for sequencial access.
        public Specification(string spec) : base(spec, null)
        {
            SharedData = new SharedDataObjects();
            LockSpecificationData();

            ParseSpec(spec, "");
        }