Serialize

Smpp v3.4 client

Moderator: alt

Locked
stevep
Posts: 30
Joined: Wed May 02, 2007 7:41 pm

Serialize

Post by stevep » Wed May 09, 2007 11:46 am

In my project I want to pass messages between applications via MSMQ or shared database fields. Is there a way to serialize the SubmitSm object or load unload the complete object from a byte string?

Steve
alt
Site Admin
Posts: 988
Joined: Tue Apr 25, 2006 9:45 am

Post by alt » Wed May 09, 2007 4:45 pm

Each SMPP packet has method GetBytes which returns byte array of this packet. Opposite serialization currently not implemented.
stevep
Posts: 30
Joined: Wed May 02, 2007 7:41 pm

Post by stevep » Sun Jul 01, 2007 10:26 am

Hi,

Do you have any plan to serialise the data so that the whole component could be loaded and unloaded from a Byte array. I have this functionality now with the other component I use, I can not move without it personally.

Steve
alt
Site Admin
Posts: 988
Joined: Tue Apr 25, 2006 9:45 am

Post by alt » Sun Jul 08, 2007 9:31 am

in version 1.2.4 I have implemented SubmitSm object serialization methods.
Please check it.
stevep
Posts: 30
Joined: Wed May 02, 2007 7:41 pm

Post by stevep » Sun Jul 08, 2007 7:37 pm

Brilliant..

:D

I found the SubmitSM.GetBytes to load a byte aray, how do I create an SubmitSM from the byte array?

Steve
alt
Site Admin
Posts: 988
Joined: Tue Apr 25, 2006 9:45 am

Post by alt » Mon Jul 09, 2007 8:26 am

byte[] SubmitSM.Serialize(SubmitSM submit)
SubmitSM SubmitSM.Deserialize(byte[] data)
Locked