Top "Object" questions

An object is any entity that can be manipulated by commands in a programming language.

Adding elements to object

I need to populate a json file, now I have something like this: {"element":{"id":10,"quantity":1}} And I need to …

javascript json object
Object comparison in JavaScript

What is the best way to compare objects in JavaScript? Example: var user1 = {name : "nerd", org: "dev"}; var user2 = {name : "…

javascript object comparison object-comparison
Convert Array to Object

What is the best way to convert: ['a','b','c'] to: { 0: 'a', 1: 'b', 2: 'c' }

javascript arrays node.js object
Sorting object property by values

If I have a JavaScript object such as: var list = { "you": 100, "me": 75, "foo": 116, "bar": 15 }; Is there a way to sort …

javascript sorting properties object
How to print instances of a class using print()?

I am learning the ropes in Python. When I try to print an object of class Foobar using the print() …

python class printing object
Converting a JS object to an array using jQuery

My application creates a JavaScript object, like the following: myObj= {1:[Array-Data], 2:[Array-Data]} But I need this object as an array. …

javascript jquery arrays object
Calling a function of a module by using its name (a string)

What is the best way to go about calling a function given a string with the function's name in a …

python object
How to convert an array to object in PHP?

How can I convert an array like this to an object? [128] => Array ( [status] => "Figure A. Facebook's horizontal scrollbars …

php arrays object casting
How can I access and process nested objects, arrays or JSON?

I have a nested data structure containing objects and arrays. How can I extract the information, i.e. access a …

javascript arrays object nested data-manipulation
How to pass an object from one activity to another on Android

I am trying to work on sending an object of my customer class from one Activity and display it in …

java android object android-intent android-activity