Questions tagged [data-serialization]

the process of translating data structures or object state into a format that can be universally stored (for example, in a file or memory buffer, or transmitted across a network connection link) and reconstructed later in the same or another computer environment [Wikipedia--Serialization]

Data Serialization solves the problem of porting data across disparate computer environments using a common format understood at both ends of the serialization/deserialization process. Data may be serialized into different "Data Serialization Formats" that have advantages and disadvantages under different scenarios and may be broadly categorized as either a text-based (i.e. human readable) encoding or byte-stream-based (i.e. binary) encoding.

Some popular formats include

  • XML
  • JSON
  • Google Protocol Buffers
29 questions
1
vote
1 answer

OCaml: serialize data into string with additional requirements

what I am looking for Let T be an OCaml data type, (example: type t = A | B of int), and x be a value of type T, is there a function f that satisfies the following requirements: f maps x to a string, i.e. f(x) is a string representation of x for…
Incömplete
  • 853
  • 8
  • 20
1
vote
2 answers

Windows.Storage on WP8 gives me Deserialize exception

I'm trying to save an ObservableCollection using the new method in windows phone (Windows.Storage). I have the following class which is the base for my observable collection I want to save: [DataContract] class SettingsModel :…
1
vote
1 answer

Storing and Reading NSKeyedArchived NSData to/from database

I have an object that contains a large amount of variables that needs to be saved locally as well as onto a database. This object would be serialized and stored locally using NSKeyedArchiver (in conjunction with CryptoCoder from…
1
vote
2 answers

Usage of JSON for a daily activity journal

To keep track of my new year resolutions I created a file daily.log in the following format. 8:40 AM 1/2/2013 begin:755am activity:enquired about 3x3 black board;bought book [beginning html 5] waste:facebook; meeting:old…
Animesh
  • 4,926
  • 14
  • 68
  • 110
0
votes
0 answers

What is this Serialization Syntax - And how to parse it with Ruby

I have to manipulate this data structure in Ruby. I don't know what's is the name of this syntax. And what is the Ruby gem to process it. ( spellCorrectionEnabled:true, recentSearchParam:( id:2098298945, doLogHistory:true …
LeandroS
  • 61
  • 6
0
votes
1 answer

Best way to load a mmap dictionary in Python without deserializing

Context: I've got Python processes running on the same container and I want to be able to share a read-only key-value object between them. I'm aware I could use something like Redis to share that info, but I'm looking for optimal solution in regards…
Damien
  • 1,944
  • 2
  • 18
  • 21
0
votes
3 answers

creating dictionary and adding number of occurrences from another dataset

I need help writing a for loop to add number of times an element appears in a dataset to the value of a dictionary comprehension. Here is the sample dataset: salary_data = {'Age': '39', 'Education': 'E - Bachelors', 'Occupation': 'Adm-clerical',…
imkusoh
  • 33
  • 3
0
votes
1 answer

Efficient Data Serialization format for list of arrays in Python

I have a large list of arrays (data type float32, with a few instances of int) in Python that is to be serialized via UTF-8 encoding and saved on a server. However I'm having issues with the size of the saved file exceeding storage limits. The…
Adam
  • 276
  • 3
  • 15
0
votes
1 answer

C# - Does it make sense to have an empty interface with a class level attribute to specify common behavior?

I have several classes that serve as data transfer objects (in C#). These classes are all serialized using JSON.Net to be sent to an API. Unfortunately, the property names specified in the API don't have standardized naming conventions. Some…
Andrew
  • 789
  • 7
  • 13
0
votes
0 answers

Is there an XML-like language (or any language) which allows easy expression of overlapping data?

(This is PROBABLY in the wrong site but I am unsure of where the right site is to assign this question to. Mod(s), please forgive and assist me.) I have the following sequence: cdadbcdacdbcbc I have the following example "code" attempt to tag the…
0
votes
1 answer

Unity: How to store some data from the game and restore it on the next run

In my game I have a collectible which is in abundance and I want each individual collectible to not respawn if the player has already collected it and returns to the scene. For example, there might be a hundred or so of these collectibles in one…
Zak Woolley
  • 169
  • 2
  • 15
0
votes
1 answer

Is there a data serialization language that allows objects to be used as the name for another object?

I have found JSON and YAML both lacking. I wish to do something like this (in YAML): nodes: node: "name for my node": - data - for - this - node (in JSON): {"nodes": {"node":"name for my node": { …
CommaToast
  • 11,370
  • 7
  • 54
  • 69
0
votes
2 answers

Multiple serialisation decorations for WCF

Does anyone know whether it is possible to have 2 different endpoints using 2 different Contract Serializers? Particularly, the default DataContractSerializer for SOAP/XML and Json.NET serializer for REST/JSON The aim (due compatibilities issues) is…
mrd3650
  • 1,371
  • 3
  • 16
  • 24
-1
votes
1 answer

Efficient screen capture program

Im looking to create a sort of remote desktop software, and it is required that i transfer the users screen over the internet to the viewer. My goal is to create an optimized capture so that i dont have to transfer the whole screen 10 times a…
caesay
  • 16,932
  • 15
  • 95
  • 160
1
2