473,466 Members | 1,531 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Specification for serialize()

It looks like I'm going to have to write programs in another language to
encode and decode php serialized data. I am really only interested in the
permutations of how it encodes multi-dimensioned arrays holding various data
types.

Is there a formal spec for how serialize() does it's thing? I can certainly
intuit much of this from looking at the results but I don't want to miss
coding for some (obscure) data type.

Daniel Klein
Mar 16 '08 #1
2 1970
On 16 Mar, 01:04, Daniel Klein <dani...@featherbrain.netwrote:
It looks like I'm going to have to write programs in another language to
encode and decode php serialized data. I am really only interested in the
permutations of how it encodes multi-dimensioned arrays holding various data
types.

Is there a formal spec for how serialize() does it's thing? I can certainly
intuit much of this from looking at the results but I don't want to miss
coding for some (obscure) data type.

Daniel Klein
Its fairly straightforward - if you serialize some stuff and write it
to disk you'll see - but it always feels wrong to me to use
serialization as a storage / messaging format since the format does
not seem to have a formal, published definition.

How painful could it it be to write the data in a format you define
yourself? Or use an off-the-shelf XML mapper?

C.
Mar 16 '08 #2
On Sun, 16 Mar 2008 14:56:28 -0700 (PDT), "C.
(http://symcbean.blogspot.com/)" <co************@gmail.comwrote:
>On 16 Mar, 01:04, Daniel Klein <dani...@featherbrain.netwrote:
>It looks like I'm going to have to write programs in another language to
encode and decode php serialized data. I am really only interested in the
permutations of how it encodes multi-dimensioned arrays holding various data
types.

Is there a formal spec for how serialize() does it's thing? I can certainly
intuit much of this from looking at the results but I don't want to miss
coding for some (obscure) data type.

Daniel Klein

Its fairly straightforward - if you serialize some stuff and write it
to disk you'll see - but it always feels wrong to me to use
serialization as a storage / messaging format since the format does
not seem to have a formal, published definition.

How painful could it it be to write the data in a format you define
yourself? Or use an off-the-shelf XML mapper?

C.
The intention was to use the result of the serialization as an intermediate
format, not for database storage.

But you're right, I am better off rolling my own.

Dan
Mar 17 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: kasiviswanath | last post by:
Hello, I'm using Xerces-c++ 2.2.0 API. I'm trying to serialize the DOM document to XML file but could n't find an equvivalent API for the same. Could some one give me pointer to the same. ...
5
by: David Sworder | last post by:
Hi, I've created a UserControl-derived class called MyUserControl that is able to persist and subsequently reload its state. It exposes two methods as follows: public void Serialize(Stream...
10
by: Dan | last post by:
All I Am Attempting To Serialize An Object To An XML File. Here Is The Code For That public string SaveNewSurvey( MutualSurveyObject mso_TempObject, int i_JobID ) { string s_RootFileName;...
0
by: Tim_Mac | last post by:
hi, i am able to serialize a normal generic List<> no problem. But when i try to serialize a Dictionary<string,string>, i get an exception as shown below: "The type...
1
by: js | last post by:
Does anybody knows how to solve the problem? I added attribute to the following classes in Microsoft.Practices.EnterpriseLibrary.Data namespace, but I still get the error. Thanks. ...
8
by: cd~ | last post by:
I can provide a test app, the news server won't allow me to post the files because they are too large (93KB and 1.2KB) I downloaded the ESRI ArcXml schema and generated the classes from the...
1
by: Tim | last post by:
Could anyone tell me what this means and how do I correct it. Any suggestions? Thanks! Tim Richardson IT Developer and Consultant www.paladin3d.com Unable to serialize the session state. In...
4
by: Hone | last post by:
I'm trying to serialize/deserialize the XML for an RSS 1.0 Feed (i.e. RDF) and the root element, as required by the standard, looks like this: <rdf:RDF ...> </rdf:RDF> However, I've tried...
4
by: =?Utf-8?B?Qnlyb24=?= | last post by:
When I try to serialize an instance of the LocationCell below (note Building field) I get an error in the reflection attempt. If I remove the _Building field it serializes fine. I tried renaming...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.