Skip to main content

Questions tagged [boxing]

Boxing is the process of placing a primitive type within an object so that the primitive can be used as a reference object.

7 votes
2 answers
819 views

I got a webservice that accepts multiple calls that require different handling and validation, using generics I've managed to create a common class that accepts a handler and a validator and it looks ...
Zalomon's user avatar
  • 1,200
4 votes
6 answers
1k views

Is boxing of primitives required in OO languages to keep them consistent with the rest of the object system (generics etc.)? Or is it avoidable - is it possible to avoid any additional performance ...
zduny's user avatar
  • 2,633
0 votes
2 answers
686 views

I was getting tired of repeating types when writing things like this: NSDictionary* d = @{@"so": [NSNumber numberWithInt:index]), @"much": [NSNumber numberWithBool:accepted]), ...
Craig Gidney's user avatar