All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class netbula.ORPC.Pmap

java.lang.Object
   |
   +----netbula.ORPC.Pmap

public class Pmap
extends Object
implements XDT
The Pmap class is the interface to the portmapper. It can query the portmapper, it can also perform broadcast RPCs.


Variable Index

 o PMAPPORT
 o PMAPPROC_CALLIT
 o PMAPPROC_DUMP
 o PMAPPROC_GETPORT
 o PMAPPROC_NULL
 o PMAPPROC_SET
 o PMAPPROC_UNSET
 o PMAPPROG
 o PMAPVERS
 o PMAPVERS_ORIG
 o PMAPVERS_PROTO
 o port
 o prog
 o prot
 o vers

Constructor Index

 o Pmap()
 o Pmap(int, int, int, int)
When adding an entry to portmapper, one needs to use this constructor and then call the set() method.

Method Index

 o broadcastCall(String, int, int, int, XDT, XDT, ReplyHandler)
Broadcast RPC (prog, vers, proc, UDP) through portmappers on the net
 o Clone()
 o dump(InetAddress)
Get the list of registered RPC servers from portmapper
 o getArray(int)
 o getPort(InetAddress)
Get the port number of the RPC defined by (prog, vers, proto)
 o rmtcall(InetAddress, int, int, int, XDT, XDT, int)
Call the RPC (prog, vers, proc, UDP) through the remote portmapper
 o set(InetAddress)
Add the entry (prog, ver, proto, port) to the portmapper service.
 o unset(InetAddress)
Remove the entry (prog, ver, proto, port) from the portmapper service
 o xdr(XDR)

Variables

 o PMAPPORT
 public static final int PMAPPORT
 o PMAPPROG
 public static final int PMAPPROG
 o PMAPVERS
 public static final int PMAPVERS
 o PMAPVERS_PROTO
 public static final int PMAPVERS_PROTO
 o PMAPVERS_ORIG
 public static final int PMAPVERS_ORIG
 o PMAPPROC_NULL
 public static final int PMAPPROC_NULL
 o PMAPPROC_SET
 public static final int PMAPPROC_SET
 o PMAPPROC_UNSET
 public static final int PMAPPROC_UNSET
 o PMAPPROC_GETPORT
 public static final int PMAPPROC_GETPORT
 o PMAPPROC_DUMP
 public static final int PMAPPROC_DUMP
 o PMAPPROC_CALLIT
 public static final int PMAPPROC_CALLIT
 o prog
 public int prog
 o vers
 public int vers
 o prot
 public int prot
 o port
 public int port

Constructors

 o Pmap
 public Pmap()
 o Pmap
 public Pmap(int p,
             int v,
             int proto,
             int portno)
When adding an entry to portmapper, one needs to use this constructor and then call the set() method.

Methods

 o Clone
 public XDT Clone()
 o getArray
 public XDT[] getArray(int len)
 o xdr
 public void xdr(XDR xdrs) throws XDRError
 o set
 public boolean set(InetAddress inetAddress)
Add the entry (prog, ver, proto, port) to the portmapper service.

Parameters:
inetAddress - address of the server where portmapper is running
Returns:
true on success, false on failure
 o unset
 public boolean unset(InetAddress inetAddress)
Remove the entry (prog, ver, proto, port) from the portmapper service

Parameters:
inetAddress - address of the server where portmapper is running
Returns:
true on success, false on failure
 o getPort
 public int getPort(InetAddress inetAddress) throws rpc_err
Get the port number of the RPC defined by (prog, vers, proto)

Parameters:
inetAddress - address at which the RPC server is running
Returns:
port number of the server
 o dump
 public pmaplist dump(InetAddress inetAddress) throws rpc_err
Get the list of registered RPC servers from portmapper

Parameters:
inetAddress - internet address of the remote machine
Returns:
list of port map entries
 o rmtcall
 public static int rmtcall(InetAddress serv,
                           int prog,
                           int vers,
                           int proc,
                           XDT args,
                           XDT res,
                           int timeout) throws rpc_err
Call the RPC (prog, vers, proc, UDP) through the remote portmapper

Parameters:
serv - remote server address
prog - program number of the RPC service
vers - version number of the RPC service
proc - procedure number to call
args - input argument
res - result argument
timeout - Timeout value
 o broadcastCall
 public static boolean broadcastCall(String baddr,
                                     int prog,
                                     int vers,
                                     int proc,
                                     XDT args,
                                     XDT res,
                                     ReplyHandler handler) throws rpc_err
Broadcast RPC (prog, vers, proc, UDP) through portmappers on the net

Parameters:
baddr - broadcast address, if null, "255.255.255.255" will be used.
prog - program number of the RPC service
vers - version number of the RPC service
proc - procedure number to call
args - input argument
res - result argument
handler - the reply handler
See Also:
ReplyHandler

All Packages  Class Hierarchy  This Package  Previous  Next  Index