Compartilhar via


OutputCacheProfile.NoStore Propriedade

Definição

Obtém ou define um valor que indica se o armazenamento secundário está habilitado.

public:
 property bool NoStore { bool get(); void set(bool value); };
[System.Configuration.ConfigurationProperty("noStore", DefaultValue=false)]
public bool NoStore { get; set; }
[<System.Configuration.ConfigurationProperty("noStore", DefaultValue=false)>]
member this.NoStore : bool with get, set
Public Property NoStore As Boolean

Valor da propriedade

Boolean

true se o armazenamento secundário estiver habilitado; caso contrário, false. O valor padrão é false.

Atributos

Exemplos

O exemplo de código a seguir mostra como usar a NoStore propriedade.


// Get the current NoStore.
Boolean noStoreValue = 
    outputCacheProfile.NoStore;

// Set the NoStore.
outputCacheProfile.NoStore = false;
  ' Get the current NoStore.
  Dim noStoreValue As [Boolean] = _
  outputCacheProfile.NoStore

  ' Set the NoStore property.
outputCacheProfile.NoStore = False

Comentários

A página que tem a OutputCacheProfile.NoStore propriedade definida para true emitir uma resposta especificando em seu cabeçalho para impedir o armazenamento secundário de informações confidenciais.

Definir esse atributo true é equivalente a invocar o HttpCachePolicy.SetNoStore método durante uma solicitação da Web.

Aplica-se a

Confira também