×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Mar 2003
    Posts
    2

    serialise object

    is it possible to send an object (serialise) using j2me? if not, is there any alternative for sending an object that could be rebuilt at the server side?

  2. #2
    Registered User
    Join Date
    Mar 2003
    Posts
    11

    RE: serialise object

    I assume that you're referring to J2ME/MIDP.

    Mobile Information Device Profile (MIDP) is built over Connected Limited Device Configuration (CLDC). CLDC specification says (5.2.3) that CLDC-conforming Java Virtual Machine does not have reflection features (i.e. features that allow inspection of object structure).

    Consquently, as Java's serialisation relies on reflection, the default serialisation behaviour is not available on J2ME/CLDC/MIDP combination.

    Object serialisation, also known as object marshalling, can however be achieved by coding the functionality by yourself: decide what fields in the object are required in order to save the object's state, define a suitable transfer protocol, and on server side, do de-serialisation.


    Conclusion: Automatic object serialisation is not available on J2ME/CLDC. This functionality can, however, be done on each specific case with some coding.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×