|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavacard.framework.service.CardRemoteObject
com.licel.jcardsim.samples.photocard.PhotoCardImpl
public class PhotoCardImpl
Field Summary |
---|
Fields inherited from interface com.licel.jcardsim.samples.photocard.PhotoCard |
---|
INVALID_ARGUMENT, INVALID_PHOTO_ID, MAX_BUFFER_BYTES, MAX_PHOTO_COUNT, MAX_SIZE, NO_PHOTO_STORED, NO_SPACE_AVAILABLE |
Method Summary | |
---|---|
void |
deletePhoto(short photoID)
This method deletes the photo whose ID is specified in the card. |
byte[] |
getPhoto(short photoID,
short offset,
short size)
This method retrueves a series of bytes belonging to the photo from the smart card at the position specified. |
short |
getPhotoSize(short photoID)
This method retrieves the photo size whose ID is specified. |
void |
loadPhoto(short photoID,
byte[] data,
short size,
short offset,
boolean more)
This method loads a series of bytes belonging to the photo into the smart card at the position specified. |
short |
requestPhotoStorage(short size)
This method requests the smart card to allocate space to store a photo image of the specified size. |
Methods inherited from class javacard.framework.service.CardRemoteObject |
---|
export, unexport |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public short requestPhotoStorage(short size) throws RemoteException, UserException
PhotoCard
requestPhotoStorage
in interface PhotoCard
size
- - Image size to store in the smart card
UserException
- - thrown if error condition occurs, or
invalid parameters passed.
RemoteException
public void loadPhoto(short photoID, byte[] data, short size, short offset, boolean more) throws RemoteException, UserException
PhotoCard
photoID
- - photo slot where to store datadata
- - byte array contaiing binary photo informationsize
- - number of bytes being passed into the smart cardoffset
- - position inside photo buffer where to store data.
UserException
- - thrown if error condition occurs, or
invalid parameters passed.
RemoteException
public void deletePhoto(short photoID) throws RemoteException, UserException
PhotoCard
deletePhoto
in interface PhotoCard
photoID
- - ID slot of photo to delete
UserException
- - thrown if error condition occurs, or
invalid parameters passed.
RemoteException
public short getPhotoSize(short photoID) throws RemoteException, UserException
PhotoCard
getPhotoSize
in interface PhotoCard
photoID
- - ID slot of photo to access
UserException
- - thrown if error condition occurs, or
invalid parameters passed.
RemoteException
public byte[] getPhoto(short photoID, short offset, short size) throws RemoteException, UserException
PhotoCard
photoID
- - photo slot where to store dataoffset
- - position inside photo buffer where to access data.size
- - number of bytes expected from the smart card
UserException
- - thrown if error condition occurs, or
invalid parameters passed.
RemoteException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |