Constructors in Java Wrapper classes | Core Java Concepts

This Core Java Concepts “Constructors in Java Wrapper classes” post is providing information about how to use constructors in wrapper classes to constructor Objects of different primitive types in java application.


 

Byte class constructors:

  • Byte class is having 2 pre-defined constructors to construct
  1. Byte Object from Primitive byte
  2. Byte Object from String.

 

  • Among 6 data conversions, we can perform only 2 conversions using constructors because only in 2 cases, output of conversion is Byte Object.

Byte class constructors in Java

 

 

Share this