Class: TencentCloud::Cdn::V20180606::SimpleCacheRule

Inherits:
TencentCloud::Common::AbstractModel
  • Object
show all
Defined in:
lib/v20180606/models.rb

Overview

缓存过期规则配置

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cachetype = nil, cachecontents = nil, cachetime = nil) ⇒ SimpleCacheRule

Returns a new instance of SimpleCacheRule.



12884
12885
12886
12887
12888
# File 'lib/v20180606/models.rb', line 12884

def initialize(cachetype=nil, cachecontents=nil, cachetime=nil)
  @CacheType = cachetype
  @CacheContents = cachecontents
  @CacheTime = cachetime
end

Instance Attribute Details

#CacheContentsObject

all:所有文件生效 file:指定文件后缀生效 directory:指定路径生效 path:指定绝对路径生效 index:首页 all 时填充 * file 时填充后缀名,如 jpg、txt directory 时填充路径,如 /xxx/test path 时填充绝对路径,如 /xxx/test.html index 时填充 / 单位为秒,最大可设置为 365 天

Parameters:

  • CacheType:

    规则类型:

  • CacheContents:

    CacheType 对应类型下的匹配内容:

  • CacheTime:

    缓存过期时间设置



12882
12883
12884
# File 'lib/v20180606/models.rb', line 12882

def CacheContents
  @CacheContents
end

#CacheTimeObject

all:所有文件生效 file:指定文件后缀生效 directory:指定路径生效 path:指定绝对路径生效 index:首页 all 时填充 * file 时填充后缀名,如 jpg、txt directory 时填充路径,如 /xxx/test path 时填充绝对路径,如 /xxx/test.html index 时填充 / 单位为秒,最大可设置为 365 天

Parameters:

  • CacheType:

    规则类型:

  • CacheContents:

    CacheType 对应类型下的匹配内容:

  • CacheTime:

    缓存过期时间设置



12882
12883
12884
# File 'lib/v20180606/models.rb', line 12882

def CacheTime
  @CacheTime
end

#CacheTypeObject

all:所有文件生效 file:指定文件后缀生效 directory:指定路径生效 path:指定绝对路径生效 index:首页 all 时填充 * file 时填充后缀名,如 jpg、txt directory 时填充路径,如 /xxx/test path 时填充绝对路径,如 /xxx/test.html index 时填充 / 单位为秒,最大可设置为 365 天

Parameters:

  • CacheType:

    规则类型:

  • CacheContents:

    CacheType 对应类型下的匹配内容:

  • CacheTime:

    缓存过期时间设置



12882
12883
12884
# File 'lib/v20180606/models.rb', line 12882

def CacheType
  @CacheType
end

Instance Method Details

#deserialize(params) ⇒ Object



12890
12891
12892
12893
12894
# File 'lib/v20180606/models.rb', line 12890

def deserialize(params)
  @CacheType = params['CacheType']
  @CacheContents = params['CacheContents']
  @CacheTime = params['CacheTime']
end