CacheDependency.SetUtcLastModified メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > CacheDependency.SetUtcLastModified メソッドの意味・解説 

CacheDependency.SetUtcLastModified メソッド

メモ : このメソッドは、.NET Framework version 2.0新しく追加されたものです。

依存関係最後に変更され時刻マーク付けます

名前空間: System.Web.Caching
アセンブリ: System.Web (system.web.dll 内)
構文構文

Protected Sub SetUtcLastModified ( _
    utcLastModified As DateTime _
)
Dim utcLastModified As DateTime

Me.SetUtcLastModified(utcLastModified)
protected void SetUtcLastModified (
    DateTime utcLastModified
)
protected:
void SetUtcLastModified (
    DateTime utcLastModified
)
protected void SetUtcLastModified (
    DateTime utcLastModified
)
protected function SetUtcLastModified (
    utcLastModified : DateTime
)

パラメータ

utcLastModified

依存関係最後に変更され時刻

使用例使用例

CacheDependency クラスから継承されるクラスコード例次に示しますSetUtcLastModified メソッド使用して依存関係変更され時刻変更するパブリック メソッド ResetDependency作成してから、NotifyDependencyChanged メソッド呼び出します。

' Declare the class.
Public Class CustomCacheDependency 
   Inherits CacheDependency

     ' Constructor with no arguments 
     ' provided by CacheDependency class.
     Public Sub New()
     End Sub ' New
   
     ' Declare a Boolean field named disposedValue.
     ' This will be used by Disposed property.
     Private disposedValue As Boolean
                
     
     ' Create accessors for the Disposed property.
     Public Property Disposed As
 Boolean
       Get
           Return disposedValue
       End Get
       Set (ByVal value As
 Boolean)
           disposedValue = value
       End Set
     End Property
     
     ' Create a public method that sets the latest
     ' changed time of the CustomCacheDependency
     ' and notifies the underlying CacheDependency that the 
     ' dependency has changed, even though the HasChanged
     ' property is false.
     Public Sub ResetDependency()
        If Me.HasChanged = False
              
           SetUtcLastModified(DateTime.MinValue)
           NotifyDependencyChanged(Me, EventArgs.Empty)
        End If
     End Sub
     
     ' Overrides the DependencyDispose method to set the
     ' Disposed proerty to true. This method automatically
     ' notifies the underlying CacheDependency object to 
     ' release any resources associated with this class. 
     Protected Overrides Sub
 DependencyDispose()
        Disposed = True
     End Sub
     
     
 End Class
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
CacheDependency クラス
CacheDependency メンバ
System.Web.Caching 名前空間



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

CacheDependency.SetUtcLastModified メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



CacheDependency.SetUtcLastModified メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS