C# Класс Microsoft.ResourceManagement.Client.DefaultClient

The DefaultClient is a thin wrapper over the the following clients: WsTransfer, WsTransferFactory, WsEnumeration , Alternate, STS It is intended to be useful only for common scenarios. For more advanced scenarios, please use the other clients.
Please note that you should call RefreshSchema before using the client for the first time, as otherwise the request and resource factories will use (incorrect) default information.
Наследование: IDisposable
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
questionHandler QAGateQuestionsHandler

Открытые методы

Метод Описание
Approve ( RmApproval approval, bool isApproved ) : void

Submits an approval response message for the pending approval using the default approval endpoint configuration name (ServiceMultipleTokenBinding_ResourceFactory).

Approve ( RmApproval approval, bool isApproved, EndpointAddress address ) : void

Submits an approval response message for the pending approval using the specified endpoint address and the default approval endpoint configuration name (ServiceMultipleTokenBinding_ResourceFactory). Use this overload e.g. if you need to specify explicitly a service principal name.

Approve ( RmApproval approval, bool isApproved, EndpointAddress address, string approvalConfiguration ) : void

Submits an approval response message for the pending approval using the specified endpoint address and the specified approval endpoint configuration name. Use this overload e.g. if you need to specify explicitly a service principal name.

Approve ( RmApproval approval, bool isApproved, string approvalConfiguration ) : void

Submits an approval response message for the pending approval using the specified approval endpoint configuration name.

Create ( RmResource newResource ) : RmReference

Creates the given resource and returns its ObjectId. This method does not set the ObjectId of newResource.

DefaultClient ( ) : System

Default constructor.

DefaultClient ( String wsTransferConfigurationName, String wsTransferFactoryConfigurationName, String wsEnumerationConfigurationName, String mexConfigurationName, String alternateClientConfigurationName ) : System

Constructor.

DefaultClient ( String wsTransferConfigurationName, String wsTransferEndpointAddress, String wsTransferFactoryConfigurationName, String wsTransferFactoryEndpointAddress, String wsEnumerationConfigurationName, String wsEnumerationEndpointAddress, String mexConfigurationName, String mexEndpointAddress, String alternateClientConfigurationName, String alternamteClientConfigurationAddress ) : System

Constructor.

DefaultClient ( string fimUrl, System.TimeSpan receiveTimeout = null, int maxReceivedMessageSize = null ) : System
Delete ( RmReference objectId ) : bool

Deletes the object with the given ObjectId.

Dispose ( ) : void

Dispose

Enumerate ( String filter ) : IEnumerable

Returns an enumerator that can traverse all objects matching the given filter.

Enumerate ( String filter, String attributes ) : IEnumerable

Returns an enumerator that can traverse all objects matching the given filter. Each object only contains the specified attributes.

Get ( RmReference objectId ) : RmResource

Retrieves the object with the given ObjectId

Get ( RmReference objectId, CultureInfo culture ) : RmResource

Retrieves the representation of an object with the given ObjectId in the given culture.

Get ( RmReference objectId, String attributes ) : RmResource

Retrieves the object and the specified attributes with the given ObjectId.

Put ( RmResourceChanges transaction ) : bool

Saves changes made to an object recorded by the transaction to the service.

Put ( RmResourceChanges transaction, bool useAlternateEndpoint ) : bool
Put ( RmResourceChanges transaction, bool useAlternateEndpoint, PutResponse &response, System.IdentityModel.Tokens.SecurityToken token, System.ServiceModel.Channels.ContextMessageProperty context ) : bool
RefreshSchema ( ) : XmlSchemaSet

Refreshes the metadata from the service.

ResetPassword ( String domainAndUserName ) : void

Защищенные методы

Метод Описание
AskQAGateQuestions ( QAGateQuestionsHandler gateHandler ) : String>.Dictionary
Get ( RmReference objectId, CultureInfo culture, String attributes ) : RmResource

Приватные методы

Метод Описание
HandleAuthNFault ( String stsEndpointAddress, System.ServiceModel.Channels.ContextMessageProperty responseContext ) : ContextualSecurityToken

Описание методов

Approve() публичный Метод

Submits an approval response message for the pending approval using the default approval endpoint configuration name (ServiceMultipleTokenBinding_ResourceFactory).
public Approve ( RmApproval approval, bool isApproved ) : void
approval Microsoft.ResourceManagement.ObjectModel.ResourceTypes.RmApproval The approval object for which to submit an approval response.
isApproved bool True when to approve the approval. False to reject it.
Результат void

Approve() публичный Метод

Submits an approval response message for the pending approval using the specified endpoint address and the default approval endpoint configuration name (ServiceMultipleTokenBinding_ResourceFactory). Use this overload e.g. if you need to specify explicitly a service principal name.
public Approve ( RmApproval approval, bool isApproved, EndpointAddress address ) : void
approval Microsoft.ResourceManagement.ObjectModel.ResourceTypes.RmApproval The approval object for which to submit an approval response.
isApproved bool True when to approve the approval. False to reject it.
address System.ServiceModel.EndpointAddress
Результат void

Approve() публичный Метод

Submits an approval response message for the pending approval using the specified endpoint address and the specified approval endpoint configuration name. Use this overload e.g. if you need to specify explicitly a service principal name.
public Approve ( RmApproval approval, bool isApproved, EndpointAddress address, string approvalConfiguration ) : void
approval Microsoft.ResourceManagement.ObjectModel.ResourceTypes.RmApproval The approval object for which to submit an approval response.
isApproved bool True when to approve the approval. False to reject it.
address System.ServiceModel.EndpointAddress
approvalConfiguration string The approval endpoint.
Результат void

Approve() публичный Метод

Submits an approval response message for the pending approval using the specified approval endpoint configuration name.
public Approve ( RmApproval approval, bool isApproved, string approvalConfiguration ) : void
approval Microsoft.ResourceManagement.ObjectModel.ResourceTypes.RmApproval The approval object for which to submit an approval response.
isApproved bool True when to approve the approval. False to reject it.
approvalConfiguration string The approval endpoint configuration name.
Результат void

AskQAGateQuestions() защищенный Метод

protected AskQAGateQuestions ( QAGateQuestionsHandler gateHandler ) : String>.Dictionary
gateHandler QAGateQuestionsHandler
Результат String>.Dictionary

Create() публичный Метод

Creates the given resource and returns its ObjectId. This method does not set the ObjectId of newResource.
public Create ( RmResource newResource ) : RmReference
newResource Microsoft.ResourceManagement.ObjectModel.RmResource The resource to create.
Результат RmReference

DefaultClient() публичный Метод

Default constructor.
public DefaultClient ( ) : System
Результат System

DefaultClient() публичный Метод

Constructor.
public DefaultClient ( String wsTransferConfigurationName, String wsTransferFactoryConfigurationName, String wsEnumerationConfigurationName, String mexConfigurationName, String alternateClientConfigurationName ) : System
wsTransferConfigurationName String Name of the ws transfer endpoint configuration.
wsTransferFactoryConfigurationName String Name of the ws transfer factory endpoint configuration.
wsEnumerationConfigurationName String Name of the ws enumeration endpoint configuration.
mexConfigurationName String Name of the mex endpoint configuration.
alternateClientConfigurationName String
Результат System

DefaultClient() публичный Метод

Constructor.
public DefaultClient ( String wsTransferConfigurationName, String wsTransferEndpointAddress, String wsTransferFactoryConfigurationName, String wsTransferFactoryEndpointAddress, String wsEnumerationConfigurationName, String wsEnumerationEndpointAddress, String mexConfigurationName, String mexEndpointAddress, String alternateClientConfigurationName, String alternamteClientConfigurationAddress ) : System
wsTransferConfigurationName String Name of the ws transfer endpoint configuration.
wsTransferEndpointAddress String The ws transfer endpoint address.
wsTransferFactoryConfigurationName String Name of the ws transfer factory endpoint configuration.
wsTransferFactoryEndpointAddress String The ws transfer factory endpoint address.
wsEnumerationConfigurationName String Name of the ws enumeration endpoint configuration.
wsEnumerationEndpointAddress String The ws enumeration endpoint address.
mexConfigurationName String Name of the mex endpoint configuration.
mexEndpointAddress String The mex endpoint address.
alternateClientConfigurationName String
alternamteClientConfigurationAddress String
Результат System

DefaultClient() публичный Метод

public DefaultClient ( string fimUrl, System.TimeSpan receiveTimeout = null, int maxReceivedMessageSize = null ) : System
fimUrl string
receiveTimeout System.TimeSpan
maxReceivedMessageSize int
Результат System

Delete() публичный Метод

Deletes the object with the given ObjectId.
public Delete ( RmReference objectId ) : bool
objectId RmReference The ObjectId of the object to delete.
Результат bool

Dispose() публичный Метод

Dispose
public Dispose ( ) : void
Результат void

Enumerate() публичный Метод

Returns an enumerator that can traverse all objects matching the given filter.
public Enumerate ( String filter ) : IEnumerable
filter String The XPath filter of which objects to select.
Результат IEnumerable

Enumerate() публичный Метод

Returns an enumerator that can traverse all objects matching the given filter. Each object only contains the specified attributes.
public Enumerate ( String filter, String attributes ) : IEnumerable
filter String The XPath filter of which objects to select.
attributes String A list of attribute names to include in returned objects.
Результат IEnumerable

Get() публичный Метод

Retrieves the object with the given ObjectId
System.ServiceModel.FaultException thrown when failures occur.
public Get ( RmReference objectId ) : RmResource
objectId RmReference The ObjectId of the requested object.
Результат Microsoft.ResourceManagement.ObjectModel.RmResource

Get() публичный Метод

Retrieves the representation of an object with the given ObjectId in the given culture.
public Get ( RmReference objectId, CultureInfo culture ) : RmResource
objectId RmReference The ObjectId of the requested object.
culture System.Globalization.CultureInfo The requested culture representation of the object.
Результат Microsoft.ResourceManagement.ObjectModel.RmResource

Get() защищенный Метод

protected Get ( RmReference objectId, CultureInfo culture, String attributes ) : RmResource
objectId RmReference
culture System.Globalization.CultureInfo
attributes String
Результат Microsoft.ResourceManagement.ObjectModel.RmResource

Get() публичный Метод

Retrieves the object and the specified attributes with the given ObjectId.
public Get ( RmReference objectId, String attributes ) : RmResource
objectId RmReference The ObjectId of the requested object.
attributes String The list of attributes on the object to return.
Результат Microsoft.ResourceManagement.ObjectModel.RmResource

Put() публичный Метод

Saves changes made to an object recorded by the transaction to the service.
public Put ( RmResourceChanges transaction ) : bool
transaction Microsoft.ResourceManagement.ObjectModel.RmResourceChanges The transaction object which recorded changes made to a Resource object.
Результат bool

Put() публичный Метод

public Put ( RmResourceChanges transaction, bool useAlternateEndpoint ) : bool
transaction Microsoft.ResourceManagement.ObjectModel.RmResourceChanges
useAlternateEndpoint bool
Результат bool

Put() публичный Метод

public Put ( RmResourceChanges transaction, bool useAlternateEndpoint, PutResponse &response, System.IdentityModel.Tokens.SecurityToken token, System.ServiceModel.Channels.ContextMessageProperty context ) : bool
transaction Microsoft.ResourceManagement.ObjectModel.RmResourceChanges
useAlternateEndpoint bool
response Microsoft.ResourceManagement.Client.WsTransfer.PutResponse
token System.IdentityModel.Tokens.SecurityToken
context System.ServiceModel.Channels.ContextMessageProperty
Результат bool

RefreshSchema() публичный Метод

Refreshes the metadata from the service.
public RefreshSchema ( ) : XmlSchemaSet
Результат System.Xml.Schema.XmlSchemaSet

ResetPassword() публичный Метод

public ResetPassword ( String domainAndUserName ) : void
domainAndUserName String
Результат void

Описание свойств

questionHandler публичное свойство

public QAGateQuestionsHandler questionHandler
Результат QAGateQuestionsHandler