Skip to main content

Questions tagged [formatting]

-2 votes
1 answer
124 views

About formatting Here are two scenarios in which the details of the formatting are described. How should in the clean code way, this be formatted Scenario 1: Dependent functions of dependent functions ...
user13047397's user avatar
78 votes
7 answers
6k views

Many high-level programming languages have built-in features to format a number with a system-dependent currency symbol: -- Outputs $100.00 (en-US) or € 100,00 (de-AT) Console.WriteLine(100.ToString(&...
Heinzi's user avatar
  • 9,868
-4 votes
1 answer
124 views

I'm very confused about this. In most programming languages, there are string.ToUpperCase(), string.ToLowerCase(), sometimes Capitalize() (which capitalize the first letter of the string), even ...
AVAVT's user avatar
  • 111
1 vote
2 answers
186 views

I need to implement a class hierarchy and be able to implement it in multiple ways. I want to create a logical representation of a query language, and then be able to parse it to/from different ...
matanper's user avatar
  • 111
45 votes
2 answers
94k views

JSON supports the following data structures (Java equivalents): Scalar, Array/List, and Map. A Set is not supported out-of-the-box in JSON. I thought about several ways to represent a set in JSON: [...
Ron Klein's user avatar
  • 761
41 votes
6 answers
14k views

In a typical web application, dates are retrieved from the database layer strongly typed (e.g. in c# as a System.DateTime as opposed System.String). When a date needs to be expressed as a string (e....
John Wu's user avatar
  • 27k
3 votes
3 answers
3k views

Background I have a RESTful HTTP API. I have a resource. GET /my/cat HTTP/1.1 Clients may want to retrieve the image representation of this resource. GET /my/cat HTTP/1.1 Accepts: image/png ...
Paul Draper's user avatar
  • 6,088
1 vote
1 answer
988 views

I'm in charge of a comprehensive serialization format with support to serialize runtime objects (any derived type of Object). I can't find a sane scenario where one would choose to serialize an ...
toplel32's user avatar
  • 237

15 30 50 per page