コード例 #1
0
 public AlterCachingPolicyCommand(
     EntityType entityType,
     EntityName entityName,
     TimeSpan hotData,
     TimeSpan hotIndex) : base(entityType, entityName)
 {
     HotData  = new KustoTimeSpan(hotData);
     HotIndex = new KustoTimeSpan(hotIndex);
 }
コード例 #2
0
        public void Null()
        {
            var time = new KustoTimeSpan(null);

            Assert.Equal("time(null)", time.ToString());
        }
コード例 #3
0
        public void Mix()
        {
            var time = new KustoTimeSpan(TimeSpan.FromDays(32) + TimeSpan.FromHours(5));

            Assert.StartsWith("time(32:05", time.ToString());
        }
コード例 #4
0
        public void MilliSeconds()
        {
            var time = new KustoTimeSpan(TimeSpan.FromMilliseconds(45));

            Assert.Equal("45ms", time.ToString());
        }
コード例 #5
0
        public void Seconds()
        {
            var time = new KustoTimeSpan(TimeSpan.FromSeconds(3));

            Assert.Equal("3s", time.ToString());
        }
コード例 #6
0
        public void Minutes()
        {
            var time = new KustoTimeSpan(TimeSpan.FromMinutes(7));

            Assert.Equal("7m", time.ToString());
        }
コード例 #7
0
        public void Hours()
        {
            var time = new KustoTimeSpan(TimeSpan.FromHours(2));

            Assert.Equal("2h", time.ToString());
        }
コード例 #8
0
        public void Days()
        {
            var time = new KustoTimeSpan(TimeSpan.FromDays(5));

            Assert.Equal("5d", time.ToString());
        }