TP1RpcClient
- 〈このページの構成〉
TP1RpcClientの概要
名前空間
Hitachi.OpenTP1.ServiceModel.TP1Integration
継承関係
System.Object +- System.ServiceModel.ClientBase
実装インタフェース:
System.ServiceModel.ICommunicationObject System.IDisposable Hitachi.OpenTP1.ServiceModel.TP1Integration.ITP1Rpc
説明
WCFのクライアントから,TP1IntegrationBindingによるOpenTP1へのサービス要求を可能にする機能を提供するWCFのプロキシクラスです。
コンストラクタの一覧
|
名称 |
説明 |
|---|---|
|
TP1RpcClientオブジェクトを生成します。 |
|
|
TP1RpcClient(System.String, System.ServiceModel.EndpointAddress) |
|
|
TP1RpcClient(System.ServiceModel.Channels.Binding, System.ServiceModel.EndpointAddress) |
メソッドの一覧
|
名称 |
説明 |
|---|---|
|
Call(System.String, System.Byte[], System.Int32, System.Byte[], System.Int32&) |
TP1IntegrationBindingによるOpenTP1へのサービス要求を実行します。 |
コンストラクタの詳細
●TP1RpcClient
- 説明
-
TP1RpcClientオブジェクトを生成します。
- 宣言
-
- 【C#の場合】
public TP1RpcClient( );
- 【Visual Basicの場合】
Public New( _ )
- パラメタ
-
なし
- 例外
-
- System.InvalidOperationException
-
既定<endpoint>要素が存在しないか,複数の<endpoint>要素が存在します。
または,アプリケーション構成ファイルが存在しません。
●TP1RpcClient
- 説明
-
TP1RpcClientオブジェクトを生成します。
- 宣言
-
- 【C#の場合】
public TP1RpcClient(string endpointConfigurationName );
- 【Visual Basicの場合】
Public New(ByVal endpointConfigurationName As String _ )
- パラメタ
-
- endpointConfigurationName
-
アプリケーション構成ファイルの<endpoint>要素の名称
- 例外
-
- System.ArgumentException
-
指定された<endpoint>要素のaddress属性値が不正です。
- System.ArgumentNullException
-
<endpoint>要素の名称にnullが設定されました。
- System.InvalidOperationException
-
指定された<endpoint>要素の名称が見つかりませんでした。
または,コントラクトが不正です。
●TP1RpcClient
- 説明
-
TP1RpcClientオブジェクトを生成します。
- 宣言
-
- 【C#の場合】
public TP1RpcClient( string endpointConfigurationName, string remoteAddress );
- 【Visual Basicの場合】
Public New( _ ByVal endpointConfigurationName As String, _ ByVal remoteAddress As String _ )
- パラメタ
-
- endpointConfigurationName
-
アプリケーション構成ファイルの<endpoint>要素の名称
- remoteAddress
-
接続先のOpenTP1のURI
- 例外
-
- System.ArgumentNullException
-
<endpoint>要素の名称にnullが設定されました。
または,接続先のOpenTP1のURIにnullが設定されました。
- System.InvalidOperationException
-
指定された<endpoint>要素の名称が見つかりませんでした。
または,コントラクトが不正です。
- System.UriFormatException
-
指定された接続先のOpenTP1のURIが不正です。
●TP1RpcClient
- 説明
-
TP1RpcClientオブジェクトを生成します。
- 宣言
-
- 【C#の場合】
public TP1RpcClient( string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress );
- 【Visual Basicの場合】
Public New( _ ByVal endpointConfigurationName As String, _ ByVal remoteAddress As System.ServiceModel.EndpointAddress _ )
- パラメタ
-
- endpointConfigurationName
-
アプリケーション構成ファイルの<endpoint>要素の名称
- remoteAddress
-
接続先のOpenTP1の位置情報が設定されたEndpointAddressオブジェクト
- 例外
-
- System.ArgumentNullException
-
<endpoint>要素の名称にnullが設定されました。
または,EndpointAddressにnullが設定されました。
- System.InvalidOperationException
-
指定された<endpoint>要素の名称が見つかりませんでした。
または,コントラクトが不正です。
●TP1RpcClient
- 説明
-
TP1RpcClientオブジェクトを生成します。
- 宣言
-
- 【C#の場合】
public TP1RpcClient( System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress );
- 【Visual Basicの場合】
Public New( _ ByVal binding As System.ServiceModel.Channels.Binding, _ ByVal remoteAddress As System.ServiceModel.EndpointAddress _ )
- パラメタ
-
- binding
-
TP1IntegrationBindingオブジェクト
- remoteAddress
-
接続先のOpenTP1の位置情報が設定されたEndpointAddressオブジェクト
- 例外
-
- System.ArgumentNullException
-
TP1IntegrationBindingにnullが設定されました。
または,EndpointAddressにnullが設定されました。
メソッドの詳細
●Call
- 説明
-
OpenTP1へのサービス要求を行います。RPCの形態は,同期応答型RPCです。また,トランザクションには参加できません。
- 宣言
-
- 【C#の場合】
public sealed virtual void Call( string service, byte[] inData, int inLength, ref byte[] outData, ref int outLength );
- 【Visual Basicの場合】
Public Overrides NotOverridable Overridable Sub Call( _ ByVal service As String, _ ByVal inData() As Byte, _ ByVal inLength As Integer, _ ByRef outData() As Byte, _ ByRef outLength As Integer _ )
- パラメタ
-
- service
-
サービス名称
- inData
-
サービスの入力パラメタ
- inLength
-
サービスの入力パラメタ長を指定します。
1から1048576までの範囲が指定できます。ただし,RPC送受信メッセージの最大長拡張機能を使用した場合は,Connector .NET構成定義の<option>要素のmaxMessageSize属性値×1048576までの範囲が指定できます。
- outData
-
サービスの応答の領域を指定します。
- outLength
-
サービスの応答の長さを指定します。
1から1048576までの範囲が指定できます。ただし,RPC送受信メッセージの最大長拡張機能を使用した場合は,Connector .NET構成定義の<option>要素のmaxMessageSize属性値×1048576までの範囲が指定できます。
指定した値は,サービス側で使用する応答領域の長さとして使用されます。
サービス要求終了時,SPP.NETのサービスメソッド,またはSPPのサービス関数で指定した応答の長さがoutLengthに設定されます。
- 戻り値
-
なし
- 例外
-
- System.ServiceModel.CommunicationException
-
OpenTP1へのサービス要求に失敗しました。
次のどちらかの場合に発生します。
-
指定された引数が不正です。
-
リモートプロシジャコール(RPC)機能の実行に失敗しました。
-
- System.ArgumentException
-
接続先のOpenTP1のURIが不正です。
- System.ArgumentNullException
-
接続先のOpenTP1の情報を格納したオブジェクトが不正です。
- System.InvalidOperationException
-
指定された<endpoint>要素のaddress属性値が不正です。
- 注意事項
-
Callメソッドは,指定された引数,およびアプリケーション構成ファイル,またはSystem.ServiceModel.EndpointAddressに設定する接続先のOpenTP1のURIに従って,リモートプロシジャコール(RPC)機能を実行します。