WebScriptEnablingElement Klasa
Definicja
Włącza WebScriptEnablingBehavior dla punktu końcowego za pomocą konfiguracji.Enables the WebScriptEnablingBehavior for an endpoint through configuration.
public ref class WebScriptEnablingElement sealed : System::ServiceModel::Configuration::BehaviorExtensionElement
public sealed class WebScriptEnablingElement : System.ServiceModel.Configuration.BehaviorExtensionElement
type WebScriptEnablingElement = class
inherit BehaviorExtensionElement
Public NotInheritable Class WebScriptEnablingElement
Inherits BehaviorExtensionElement
- Dziedziczenie
-
WebScriptEnablingElement
- Dziedziczenie
-
WebScriptEnablingElement
Przykłady
Poniżej znajduje się przykład użycia tego elementu konfiguracji w celu skonfigurowania punktu końcowego programu WCF do uzyskiwania dostępu przez stronę sieci Web ASP.NET AJAX.The following is an example of using this configuration element to configure a WCF endpoint to be accessed by ASP.NET AJAX Web page.
<system.serviceModel>
<services>
<service name="Microsoft.Ajax.Samples.CalculatorService">
<endpoint address=""
behaviorConfiguration="AspNetAjaxBehavior"
binding="webHttpBinding"
contract="Microsoft.Ajax.Samples.ICalculator" />
</service>
</services>
<behaviors>
<endpointBehaviors>
<behavior name="AspNetAjaxBehavior">
<enableWebScript />
</behavior>
</endpointBehaviors>
</behaviors>
</system.serviceModel>
Uwagi
WebScriptEnablingElementTo BehaviorExtensionElement podtyp, którego można użyć do uwzględnienia WebScriptEnablingBehavior w punkcie końcowym przez konfigurację.The WebScriptEnablingElement is a BehaviorExtensionElement subtype that can be used to include the WebScriptEnablingBehavior on an endpoint through configuration. Brak konfigurowalnych właściwości dla tego elementu.There are no configurable properties on this element.
Z WebScriptEnablingBehavior kolei umożliwia dostęp do punktu końcowego za pomocą stron sieci Web ASP.NET AJAX, gdy jest on skonfigurowany przy użyciu WebHttpBinding .The WebScriptEnablingBehavior, in turn, allows an endpoint to be accessed by ASP.NET AJAX Web pages when it is configured with the WebHttpBinding.
Aby uzyskać więcej informacji na temat sposobu, w jaki usługa WCF może odpowiadać klientom ASP.NET AJAX, zobacz Tworzenie usług WCF dla ASP.NET AJAX.For more information about how to enable a WCF service to respond to ASP.NET AJAX clients, see Creating WCF Services for ASP.NET AJAX.
Konstruktory
WebScriptEnablingElement() |
Inicjuje nowe wystąpienie klasy WebScriptEnablingElement.Initializes a new instance of the WebScriptEnablingElement class. |
Właściwości
BehaviorType |
Pobiera typ zachowania włączonego przez ten element konfiguracji.Gets the type of the behavior enabled by this configuration element. |
ConfigurationElementName |
Pobiera nazwę tego elementu konfiguracji.Gets the name of this configuration element. (Odziedziczone po ServiceModelExtensionElement) |
CurrentConfiguration |
Pobiera odwołanie do wystąpienia najwyższego poziomu Configuration , które reprezentuje hierarchię konfiguracji, do której ConfigurationElement należy bieżące wystąpienie.Gets a reference to the top-level Configuration instance that represents the configuration hierarchy that the current ConfigurationElement instance belongs to. (Odziedziczone po ConfigurationElement) |
ElementInformation |
Pobiera ElementInformation obiekt, który zawiera informacje, które nie są dostosowywane i funkcje ConfigurationElement obiektu.Gets an ElementInformation object that contains the non-customizable information and functionality of the ConfigurationElement object. (Odziedziczone po ConfigurationElement) |
ElementProperty |
Pobiera ConfigurationElementProperty obiekt, który reprezentuje ConfigurationElement sam obiekt.Gets the ConfigurationElementProperty object that represents the ConfigurationElement object itself. (Odziedziczone po ConfigurationElement) |
EvaluationContext |
Pobiera ContextInformation obiekt dla ConfigurationElement obiektu.Gets the ContextInformation object for the ConfigurationElement object. (Odziedziczone po ConfigurationElement) |
HasContext |
Pobiera wartość wskazującą, czy CurrentConfiguration Właściwość jest |
Item[ConfigurationProperty] |
Pobiera lub ustawia właściwość lub atrybut tego elementu konfiguracji.Gets or sets a property or attribute of this configuration element. (Odziedziczone po ConfigurationElement) |
Item[String] |
Pobiera lub ustawia właściwość, atrybut lub element podrzędny tego elementu konfiguracji.Gets or sets a property, attribute, or child element of this configuration element. (Odziedziczone po ConfigurationElement) |
LockAllAttributesExcept |
Pobiera kolekcję zablokowanych atrybutów.Gets the collection of locked attributes. (Odziedziczone po ConfigurationElement) |
LockAllElementsExcept |
Pobiera kolekcję zablokowanych elementów.Gets the collection of locked elements. (Odziedziczone po ConfigurationElement) |
LockAttributes |
Pobiera kolekcję zablokowanych atrybutów.Gets the collection of locked attributes. (Odziedziczone po ConfigurationElement) |
LockElements |
Pobiera kolekcję zablokowanych elementów.Gets the collection of locked elements. (Odziedziczone po ConfigurationElement) |
LockItem |
Pobiera lub ustawia wartość wskazującą, czy element jest zablokowany.Gets or sets a value indicating whether the element is locked. (Odziedziczone po ConfigurationElement) |
Properties |
Pobiera kolekcję właściwości.Gets the collection of properties. (Odziedziczone po ConfigurationElement) |
Metody
CopyFrom(ServiceModelExtensionElement) |
Kopiuje zawartość określonego elementu konfiguracji do tego elementu konfiguracji.Copies the content of the specified configuration element to this configuration element. (Odziedziczone po ServiceModelExtensionElement) |
CreateBehavior() |
Tworzy rozszerzenie zachowania na podstawie bieżących ustawień konfiguracji.Creates a behavior extension based on the current configuration settings. (Odziedziczone po BehaviorExtensionElement) |
DeserializeElement(XmlReader, Boolean) |
Odczytuje dane XML z pliku konfiguracyjnego.Reads XML from the configuration file. (Odziedziczone po ConfigurationElement) |
Equals(Object) |
Porównuje bieżące ConfigurationElement wystąpienie do określonego obiektu.Compares the current ConfigurationElement instance to the specified object. (Odziedziczone po ConfigurationElement) |
GetHashCode() |
Pobiera unikatową wartość reprezentującą bieżące ConfigurationElement wystąpienie.Gets a unique value representing the current ConfigurationElement instance. (Odziedziczone po ConfigurationElement) |
GetTransformedAssemblyString(String) |
Zwraca przekształconą wersję określonej nazwy zestawu.Returns the transformed version of the specified assembly name. (Odziedziczone po ConfigurationElement) |
GetTransformedTypeString(String) |
Zwraca przekształconą wersję określonej nazwy typu.Returns the transformed version of the specified type name. (Odziedziczone po ConfigurationElement) |
GetType() |
Pobiera Type bieżące wystąpienie.Gets the Type of the current instance. (Odziedziczone po Object) |
Init() |
Ustawia ConfigurationElement obiekt do stanu początkowego.Sets the ConfigurationElement object to its initial state. (Odziedziczone po ConfigurationElement) |
InitializeDefault() |
Służy do inicjowania domyślnego zestawu wartości dla ConfigurationElement obiektu.Used to initialize a default set of values for the ConfigurationElement object. (Odziedziczone po ConfigurationElement) |
IsModified() |
Pobiera wartość określającą, czy ten element konfiguracji został zmodyfikowany.Gets a value that specifies whether this configuration element has been modified. (Odziedziczone po ServiceModelExtensionElement) |
IsReadOnly() |
Pobiera wartość wskazującą, czy ConfigurationElement obiekt jest tylko do odczytu.Gets a value indicating whether the ConfigurationElement object is read-only. (Odziedziczone po ConfigurationElement) |
ListErrors(IList) |
Dodaje błędy nieprawidłowej właściwości w tym ConfigurationElement obiekcie i we wszystkich podelementach do listy zakończonych.Adds the invalid-property errors in this ConfigurationElement object, and in all subelements, to the passed list. (Odziedziczone po ConfigurationElement) |
MemberwiseClone() |
Tworzy skróconą kopię bieżącego elementu Object .Creates a shallow copy of the current Object. (Odziedziczone po Object) |
OnDeserializeUnrecognizedAttribute(String, String) |
Pobiera wartość wskazującą, czy podczas deserializacji napotkano nieznany atrybut.Gets a value indicating whether an unknown attribute is encountered during deserialization. (Odziedziczone po ConfigurationElement) |
OnDeserializeUnrecognizedElement(String, XmlReader) |
Pobiera wartość wskazującą, czy nieznany element został napotkany podczas deserializacji.Gets a value indicating whether an unknown element is encountered during deserialization. (Odziedziczone po ConfigurationElement) |
OnRequiredPropertyNotFound(String) |
Zgłasza wyjątek, gdy wymagana właściwość nie zostanie znaleziona.Throws an exception when a required property is not found. (Odziedziczone po ConfigurationElement) |
PostDeserialize() |
Wywoływana po deserializacji.Called after deserialization. (Odziedziczone po ConfigurationElement) |
PreSerialize(XmlWriter) |
Wywoływana przed serializacji.Called before serialization. (Odziedziczone po ConfigurationElement) |
Reset(ConfigurationElement) |
Resetuje stan wewnętrzny tego obiektu elementu konfiguracji, w tym blokady i kolekcje właściwości.Resets the internal state of this configuration element object, including the locks and the properties collections. (Odziedziczone po ServiceModelExtensionElement) |
ResetModified() |
Resetuje wartość IsModified() metody do |
SerializeElement(XmlWriter, Boolean) |
Zapisuje zawartość tego elementu konfiguracji w pliku konfiguracji.Writes the contents of this configuration element to the configuration file. (Odziedziczone po ServiceModelExtensionElement) |
SerializeToXmlElement(XmlWriter, String) |
Zapisuje zewnętrzne Tagi tego elementu konfiguracji w pliku konfiguracji po zaimplementowaniu w klasie pochodnej.Writes the outer tags of this configuration element to the configuration file when implemented in a derived class. (Odziedziczone po ConfigurationElement) |
SetPropertyValue(ConfigurationProperty, Object, Boolean) |
Ustawia właściwość na określoną wartość.Sets a property to the specified value. (Odziedziczone po ConfigurationElement) |
SetPropertyValueIfNotDefaultValue<T>(String, T) |
Ustawia wartość właściwości dla elementu konfiguracji, jeśli wartość nie jest wartością domyślną.Sets the property value for the configuration element if the value is not the default value. (Odziedziczone po ServiceModelConfigurationElement) |
SetReadOnly() |
Ustawia IsReadOnly() Właściwość dla ConfigurationElement obiektu i wszystkie podelementy.Sets the IsReadOnly() property for the ConfigurationElement object and all subelements. (Odziedziczone po ConfigurationElement) |
ToString() |
Zwraca ciąg reprezentujący bieżący obiekt.Returns a string that represents the current object. (Odziedziczone po Object) |
Unmerge(ConfigurationElement, ConfigurationElement, ConfigurationSaveMode) |
Modyfikuje ConfigurationElement obiekt, aby usunąć wszystkie wartości, które nie powinny być zapisane.Modifies the ConfigurationElement object to remove all values that should not be saved. (Odziedziczone po ConfigurationElement) |