|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.rmi.server.RemoteObject | +--java.rmi.server.RemoteStub | +--suncertify.common.QueryInterfaceImpl_Stub
Constructor Summary | |
QueryInterfaceImpl_Stub(java.rmi.server.RemoteRef)
|
Method Summary | |
int |
create(java.lang.String[],
java.lang.String)
Creates a new record in the database (possibly reusing a deleted entry). |
void |
delete(int,
java.lang.String)
Deletes a record, making the record number and associated disk storage available for reuse. |
int[] |
find(java.lang.String[],
java.lang.String)
Returns an array of record numbers that match the specified criteria. |
boolean |
isLocked(int,
java.lang.String)
Determines if a record is currenly locked. |
void |
lock(int,
java.lang.String)
Locks a record so that it can only be updated or deleted by this client. |
java.lang.String |
logIn()
The method performs client login it is required as server needs to identify clients |
void |
logIn(java.lang.String)
The method performs client login it is required as server needs to identify clients |
void |
logOut(java.lang.String)
The method performs client logout - no others connections with such login will be available |
java.lang.String[] |
read(int,
java.lang.String)
Reads a record from the file. |
void |
unlock(int,
java.lang.String)
Releases the lock on a record. |
void |
update(int,
java.lang.String[],
java.lang.String)
Modifies the fields of a record. |
Methods inherited from class java.rmi.server.RemoteObject |
equals, getRef, hashCode, toString, toStub |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public QueryInterfaceImpl_Stub(java.rmi.server.RemoteRef)
Method Detail |
public int create(java.lang.String[], java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, DuplicateKeyException
QueryInterface
create
in interface QueryInterface
- the array string representig values of the fields of the new record
- the unique identifier of the clienent thet is performing request
DuplicateKeyException
- - thrown when record could not be created
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
java.rmi.RemoteException
- - required for remote accesspublic void delete(int, java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
delete
in interface QueryInterface
- the index of the record to delete
- the unique identifier of the clienent thet is performing request
java.rmi.RemoteException
- - required for remote access
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)public int[] find(java.lang.String[], java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
find
in interface QueryInterface
- String array representing the criteria for each record field
- the unique identifier of the clienent thet is performing request
java.rmi.RemoteException
- - required for remote access
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.public boolean isLocked(int, java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
isLocked
in interface QueryInterface
- the index of the record to check
- the unique identifier of the clienent thet is performing request
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.
java.rmi.RemoteException
- - required for remote accesspublic void lock(int, java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
lock
in interface QueryInterface
- the index of the record to lock
- the unique identifier of the clienent thet is performing request
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
java.rmi.RemoteException
- - required for remote access
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.public java.lang.String logIn() throws java.rmi.RemoteException
QueryInterface
logIn
in interface QueryInterface
java.rmi.RemoteException
- - required for remote accesspublic void logIn(java.lang.String) throws java.rmi.RemoteException
QueryInterface
logIn
in interface QueryInterface
- client login
java.rmi.RemoteException
- - required for remote accesspublic void logOut(java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException
QueryInterface
logOut
in interface QueryInterface
- uniqe client identifier
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
java.rmi.RemoteException
- - required for remote accesspublic java.lang.String[] read(int, java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
read
in interface QueryInterface
- the index of the requested record
- the unique identifier of the clienent thet is performing request
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.
java.rmi.RemoteException
- - required for remote accesspublic void unlock(int, java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
unlock
in interface QueryInterface
- the index of the record to lock
- the unique identifier of the clienent thet is performing request
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
java.rmi.RemoteException
- - required for remote access
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.public void update(int, java.lang.String[], java.lang.String) throws java.rmi.RemoteException, ClientNotLoggedInException, RecordNotFoundException
QueryInterface
update
in interface QueryInterface
- the index of the record to operate on
- the new set of data for the requested record
- the unique identifier of the clienent thet is performing request
ClientNotLoggedInException
- - is thrown when client login passed as argument is
not a valid client login (e.g. client has not been logged in)
RecordNotFoundException
- is thrown if a specified record does not exist or is
marked as deleted in the database file.
java.rmi.RemoteException
- - required for remote access
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |