Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / FaultContractAttribute.cs / 1 / FaultContractAttribute.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.ServiceModel { using System.Reflection; using System.ServiceModel.Security; using System.Net.Security; using System.ServiceModel.Description; [AttributeUsage(ServiceModelAttributeTargets.OperationContract, AllowMultiple = true, Inherited = false)] public sealed class FaultContractAttribute : Attribute { string action; string name; string ns; Type type; ProtectionLevel protectionLevel = ProtectionLevel.None; bool hasProtectionLevel = false; public FaultContractAttribute(Type detailType) { if (detailType == null) throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentNullException("detailType")); this.type = detailType; } public Type DetailType { get { return this.type; } } public string Action { get { return this.action; } set { if (value == null) throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("value"); this.action = value; } } public string Name { get { return this.name; } set { if (value == null) throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("value"); if (value == string.Empty) throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("value", SR.GetString(SR.SFxNameCannotBeEmpty))); this.name = value; } } public string Namespace { get { return this.ns; } set { if (!string.IsNullOrEmpty(value)) NamingHelper.CheckUriProperty(value, "Namespace"); this.ns = value; } } internal const string ProtectionLevelPropertyName = "ProtectionLevel"; public ProtectionLevel ProtectionLevel { get { return this.protectionLevel; } set { if (!ProtectionLevelHelper.IsDefined(value)) throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("value")); this.protectionLevel = value; this.hasProtectionLevel = true; } } public bool HasProtectionLevel { get { return this.hasProtectionLevel; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ValueType.cs
- SiteMapProvider.cs
- ADMembershipUser.cs
- Triangle.cs
- NamedElement.cs
- MenuItemCollection.cs
- EncryptedData.cs
- OdbcInfoMessageEvent.cs
- ListViewInsertionMark.cs
- XmlSchemaValidator.cs
- QilParameter.cs
- DataGridRelationshipRow.cs
- CompressedStack.cs
- PositiveTimeSpanValidatorAttribute.cs
- GeometryConverter.cs
- MessageDecoder.cs
- XmlComplianceUtil.cs
- Stacktrace.cs
- SizeChangedEventArgs.cs
- EntityDataSourceWrapper.cs
- DSASignatureFormatter.cs
- odbcmetadatacollectionnames.cs
- DataGridViewRowDividerDoubleClickEventArgs.cs
- XPathBinder.cs
- PermissionListSet.cs
- ScriptingWebServicesSectionGroup.cs
- SourceFileInfo.cs
- ValidationError.cs
- SystemIPInterfaceProperties.cs
- ImmutableObjectAttribute.cs
- ClientCredentialsSecurityTokenManager.cs
- SqlClientWrapperSmiStream.cs
- RSAOAEPKeyExchangeDeformatter.cs
- FontStyleConverter.cs
- TrackingMemoryStreamFactory.cs
- DbConnectionOptions.cs
- ObjectReaderCompiler.cs
- ArrayTypeMismatchException.cs
- CryptoStream.cs
- ImageDrawing.cs
- WebService.cs
- DbExpressionVisitor_TResultType.cs
- Vector3dCollection.cs
- WindowPatternIdentifiers.cs
- PageCatalogPart.cs
- SecurityAlgorithmSuite.cs
- NativeMethods.cs
- SystemColors.cs
- ViewStateModeByIdAttribute.cs
- XmlSchemaInfo.cs
- PerspectiveCamera.cs
- BooleanExpr.cs
- Group.cs
- FontStretches.cs
- SafeCertificateContext.cs
- XmlResolver.cs
- wmiutil.cs
- WinInetCache.cs
- TextViewSelectionProcessor.cs
- FreezableCollection.cs
- FormConverter.cs
- QilXmlWriter.cs
- FormatConvertedBitmap.cs
- XdrBuilder.cs
- XhtmlBasicLabelAdapter.cs
- ToolboxComponentsCreatedEventArgs.cs
- MeasureData.cs
- ListArgumentProvider.cs
- GcHandle.cs
- Closure.cs
- DataColumnMapping.cs
- AuthenticationModuleElementCollection.cs
- Rect3DConverter.cs
- MetadataImporterQuotas.cs
- ResolveMatchesCD1.cs
- MessageQueueException.cs
- XmlAnyElementAttributes.cs
- FormViewDeleteEventArgs.cs
- DataTemplateSelector.cs
- DesignerMetadata.cs
- CompilerResults.cs
- SystemFonts.cs
- MethodRental.cs
- IResourceProvider.cs
- cookiecontainer.cs
- ProtocolViolationException.cs
- TextTreeText.cs
- ConfigurationLocationCollection.cs
- COM2IPerPropertyBrowsingHandler.cs
- ApplicationProxyInternal.cs
- UnsafeNativeMethods.cs
- WindowsIdentity.cs
- BitmapEffectRenderDataResource.cs
- backend.cs
- PointF.cs
- ObjRef.cs
- XmlQueryTypeFactory.cs
- PersonalizationEntry.cs
- MergablePropertyAttribute.cs
- TopClause.cs