コード例 #1
0
ファイル: Profile.cs プロジェクト: hww/VARP2
        public Profile Start(ProfileSample sample)
        {
            var profile = GetProfile( );

            profile.Start(sample);
            return(profile);
        }
コード例 #2
0
ファイル: Profile.cs プロジェクト: hww/VARP2
 public void Stop( )
 {
     this.sample.UpdateTime(SystemTime.ElapsedMilliseconds - this.startTime);
     this.startTime = 0;
     this.sample    = null;
     this.Remove( );
 }
コード例 #3
0
ファイル: Profile.cs プロジェクト: hww/VARP2
        public static Profile StartProfile(Name name, Name parentName)
        {
            ProfileSample parentSample = GetProfile(parentName);
            ProfileSample sample       = parentSample.GetProfile(name);

            return(pofilePool.Start(sample));
        }
コード例 #4
0
ファイル: Profile.cs プロジェクト: hww/VARP2
        public ProfileSample GetProfile(Name name)
        {
            ProfileSample result = null;

            if (children.TryGetValue(name, out result))
            {
                return(result);
            }
            children[name] = result = new ProfileSample(name, this);
            return(result);
        }
コード例 #5
0
ファイル: Profile.cs プロジェクト: hww/VARP2
        private static ProfileSample GetProfile(Name name)
        {
            ProfileSample sample = null;

            if (Samples.TryGetValue(name, out sample))
            {
                return(sample);
            }
            sample        = new ProfileSample(name);
            Samples[name] = sample;
            return(sample);
        }
コード例 #6
0
ファイル: Profile.cs プロジェクト: hww/VARP2
 public void Cancel( )
 {
     this.startTime = 0;
     this.sample    = null;
     this.Remove( );
 }
コード例 #7
0
ファイル: Profile.cs プロジェクト: hww/VARP2
        public static Profile StartProfile(Name name)
        {
            ProfileSample sample = GetProfile(name);

            return(pofilePool.Start(sample));
        }
コード例 #8
0
ファイル: Profile.cs プロジェクト: hww/VARP2
 public void Start(ProfileSample sample)
 {
     this.sample    = sample;
     this.startTime = SystemTime.ElapsedMilliseconds;
 }
コード例 #9
0
ファイル: Profile.cs プロジェクト: hww/VARP2
 public void Dispose( )
 {
     parent = null;
     children.Clear( );
 }
コード例 #10
0
ファイル: Profile.cs プロジェクト: hww/VARP2
 public ProfileSample(Name name, ProfileSample parent)
 {
     this.name   = name;
     this.parent = parent;
     children    = new Dictionary <Name, ProfileSample> (DEFAULT_HASH_SIZE);
 }