
        // /jesma/releases/jesmf10/builds/20050519.5/pae22_SunOS5.8/ws/src/java/com/sun/mfwk/conn/ServiceStub.java - GENERATED BY rmi2rpc generator

package com.sun.mfwk.conn;

import java.io.*;
import java.rmi.*;
import com.sun.rmi2rpc.*;
import com.sun.rmi2rpc.rpc.*;

public class ServiceStub extends com.sun.rmi2rpc.RpcStub implements com.sun.
        mfwk.conn.Service {
    public static final int TYPE_CODE = 50506;
    public static final int VERSION_CODE = 1;

    public ServiceStub(com.sun.rmi2rpc.rpc.RpcClient rpc, com.sun.rmi2rpc.
            RpcStubCalls rpcStubCalls) {
        super(rpc, rpcStubCalls);
    }

    public com.sun.mfwk.conn.MfAttValue getAttribute(String p1, String p2)
            throws java.rmi.RemoteException {
        while (true) {
            RpcCall rpcCall = null;
            try {
                rpcCall = rpcStubCalls.newCall(rpcClient, TYPE_CODE,
                        VERSION_CODE, 0, false);
                XdrOutputStream xout = rpcCall.start();
                xout.writeBytes(p1);
                xout.writeBytes(p2);

                XdrInputStream xin = rpcCall.getReply();

                com.sun.mfwk.conn.MfAttValue value;
                value = new com.sun.mfwk.conn.MfAttValue();
                value.type = xin.readInt();
                value.value = xin.readString();
                rpcStubCalls.endCall(rpcClient, rpcCall);
                return value;
                } catch (Throwable t) {
                boolean retry =
                    rpcStubCalls.callFailed(rpcClient, rpcCall, t, (t
                            instanceof RpcException));
                if (retry)
                    continue;
                throw new FatalRpcException("RpcClientCall failed to handle",
                        t);
            }
        }
    }

    public com.sun.mfwk.conn.MfAttValue[] getAttributes(String p1, String[] p2
            ) throws java.rmi.RemoteException {
        while (true) {
            RpcCall rpcCall = null;
            try {
                rpcCall = rpcStubCalls.newCall(rpcClient, TYPE_CODE,
                        VERSION_CODE, 1, false);
                XdrOutputStream xout = rpcCall.start();
                xout.writeBytes(p1);
                xout.writeInt(p2.length);
                for (int i0 = 0; i0 < p2.length; i0++) {
                    xout.writeBytes(p2[i0]);
                }

                XdrInputStream xin = rpcCall.getReply();

                com.sun.mfwk.conn.MfAttValue[] value;
                value = new com.sun.mfwk.conn.MfAttValue[xin.readInt()];
                for (int i1 = 0; i1 < value.length; i1++) {
                    value[i1] = new com.sun.mfwk.conn.MfAttValue();
                    value[i1].type = xin.readInt();
                    value[i1].value = xin.readString();
                }
                rpcStubCalls.endCall(rpcClient, rpcCall);
                return value;
                } catch (Throwable t) {
                boolean retry =
                    rpcStubCalls.callFailed(rpcClient, rpcCall, t, (t
                            instanceof RpcException));
                if (retry)
                    continue;
                throw new FatalRpcException("RpcClientCall failed to handle",
                        t);
            }
        }
    }

    public com.sun.mfwk.conn.MfAttValue invoke(String p1, String p2, com.sun.
            mfwk.conn.MfAttValue[] p3, String[] p4) throws java.rmi.
            RemoteException {
        while (true) {
            RpcCall rpcCall = null;
            try {
                rpcCall = rpcStubCalls.newCall(rpcClient, TYPE_CODE,
                        VERSION_CODE, 2, false);
                XdrOutputStream xout = rpcCall.start();
                xout.writeBytes(p1);
                xout.writeBytes(p2);
                xout.writeInt(p3.length);
                for (int i2 = 0; i2 < p3.length; i2++) {
                    xout.writeInt(p3[i2].type);
                    xout.writeBytes(p3[i2].value);
                }
                xout.writeInt(p4.length);
                for (int i3 = 0; i3 < p4.length; i3++) {
                    xout.writeBytes(p4[i3]);
                }

                XdrInputStream xin = rpcCall.getReply();

                com.sun.mfwk.conn.MfAttValue value;
                value = new com.sun.mfwk.conn.MfAttValue();
                value.type = xin.readInt();
                value.value = xin.readString();
                rpcStubCalls.endCall(rpcClient, rpcCall);
                return value;
                } catch (Throwable t) {
                boolean retry =
                    rpcStubCalls.callFailed(rpcClient, rpcCall, t, (t
                            instanceof RpcException));
                if (retry)
                    continue;
                throw new FatalRpcException("RpcClientCall failed to handle",
                        t);
            }
        }
    }

}
