All Questions
69
questions
0
votes
0
answers
20
views
PHP Deserialize JSON array and Get object name [duplicate]
how to get the object name? e.g: “XXX.HOSTNAME”
$json = '{
"XXX.HOSTNAME": {
"IP": "123.195.214.93",
"IP6": "",
"...
0
votes
1
answer
134
views
Convert Python Class with Inner Classes and Static Attributes to JSON
I am trying to convert the following to json.
@dataclass
class Attribute:
name: str
description: str
class A:
class B:
attr1 = Attribute(name="attr1",description="...
1
vote
1
answer
2k
views
How can we deserialize JSON data to c# object from API response
I need to deserialize my json data. I am using Newtonsoft.Json for json operations. I tried a lot of method to deserialize this data but i failed. Btw, I need to summarize my system for better ...
1
vote
1
answer
568
views
Serialize Python object in another object with json?
how can I serialize an object which has another object in his attributes using TinyDB ?
class address:
def __init__(self, country, city):
self.country = country
self.city = city
...
5
votes
2
answers
1k
views
Creating a nested object from entries
Is there a way to generate a nested JavaScript Object from entries?
Object.fromEntries() doesn't quite do it since it doesn't do nested objects.
const entries = [['a.b', 'c'], ['a.d', 'e']]
// Object....
3
votes
3
answers
285
views
How to convert string values into numbers and booleans from an object?
For exmaple if I have a JavaScript Object like,
{
id: "234",
name: "shreyas",
active: "true"
}
How can I convert it to like this
{
id: 234,
name: &...
0
votes
2
answers
646
views
Iterate through nested objects from json c#
I have received a Json file which I have to deal with. I have no idea over the structure. My goal is to deserialize the Json and write a function which allows me to iterate through all the given ...
0
votes
1
answer
208
views
Json having repeated key name in different node
I am working in json. In json data key is repeated in different node in single json. it is a response json. how can i make a serialized class for this json class.
In below json data is repeated is ...
-1
votes
1
answer
49
views
Unable to deseralize JSON String to a C# Object
Im trying to convert a JSON string retrived from https://my-json-server.typicode.com/dskato/UDLAProyectoApi/posts to a list of my "Customer" object
The data is coming good but when i try to ...
1
vote
0
answers
932
views
Delphi - Serialization of objects : ignore inherited properties
I'm trying to learn how to serialize objects with Delphi 10.3.3 Rio using this units : REST.JsonReflect and REST.JSON.Types
I wrote this class :
TContainer: class(TGraphicControl)
private
[...
1
vote
1
answer
195
views
JsonConvert.DeserializeObject object from API using Webclient that could be one of 2 Object types
I am trying to access the FitBit API, with C# .Net Core 3.1
https://dev.fitbit.com/build/reference/web-api/sleep/
However, for sleep data, it could return the SleepJSON object or a Meta object that ...
0
votes
1
answer
187
views
VB.NET DataContractJsonSerializer Nested Object Formatting
I have a problem with the outcome of a serialization. The class i serialize looks like this:
<Runtime.Serialization.DataContract()>
Public Class ResponseJSON
<Runtime....
0
votes
2
answers
124
views
How to serilize/deserilize Json Object to C# class
I have two json responses that have "resultObject" property. One of them has returned object, other one has returned string/bool.
I have a C# object that use from JSON.
public class UseInboxResult
{ ...
2
votes
2
answers
69
views
How to reduce duplicate nested dictionary levels while serializing python object
I have an example python script below where, Market object has fruits object which contains dictionary of different type of fruit objects.
While serializing the market object as shown below,
import ...
0
votes
1
answer
68
views
deserialization xml string as string element c#
i have a xml string like this:
<root>
<header>
<reqType>REQUEST</reqType>
<priority>1</priority>
<channel>TTP</channel>
...