×

Unicode System in Java

In this tutorial, we will understand the meaning and emergence of the Unicode system in java. The Unicode system is one of the important and useful features in the world of programming. So, we will try to understand it precisely. We will have a glance at its utility in the programming world. We will see a list of Unicode values along with their description.

Understanding the term

Unicode stands for universal international standard character encoding. It is capable of representing a large of written languages around the globe. It represents digits, alphabets both uppercase and lowercase, and, special characters.

As we know computers understand numbers, so our inputs get coded in certain languages that computers can easily understand.

The Unicode system assigns a unique number to each character which is independent of the platform, and language. It is the standard language.

Unicode is not the first system of encoding to be used. Before this, many other systems were being used such as –

  • SO 8859-1 for Western European Language.
  • KOI-8 for Russia
  • ASCII for the United States of America

These earlier systems had certain limitations which resulted in the new system i.e Unicode system.

The two major limitations include the following:

  1. A specific code value links to different letters in many language standards.
  2. The encodings for languages with huge character sets have variable lengths. Some common characters are encoded as single by others who require two or more bytes.
  3. Limitation in size. Those are capable of encoding up to a certain capacity which is less for the technically growing era.

The Unicode system solves the above problems and it holds characters of size 2 bytes and java too, the size of the character is 2 bytes.

Unicode is capable of handling 10,000 characters whereas ASCII values can handle only 128 characters.

The Unicode value is capable of storing all the existing texts and also the forthcoming ones.

Unicode values are needed for the standardization of texts.

Here, The range of Unicode values starts from \u0000 and ends at \uFFFF. Thus, we can say that \u0000 is the lowest or the smallest Unicode value and \uFFFF is the highest Unicode value.

Example

Now, let us have a look at examples to understand the concept even better.

Unicode         Char   Description

U+0000          ^@      Null character

U+0001          ^A       Start of heading (it is not the alphabetic A)

U+0002          ^B       Start of text(it is not the B of alphabets)

U+0003          ^C       End of text

U+0004          ^D       End of transmission

U+0005          ^E        Enquiry

U+0006          ^F        Acknowledge

U+0007          ^G       Bell 

U+0008          ^H       Backspace

U+0009          ^I         Horizontal tab 

U+000A          ^J        Line feed 

U+000B          ^K        Vertical tab

U+000C          ^L        New page

U+000D          ^M      return of Carriage

U+000E          ^N       Shift out 

U+000F          ^O       Shift in

U+0010          ^P        Data link escape 

U+0011          ^Q       Device Control 1 

U+0012          ^R       Device Control2 

U+0013          ^S        Device Control3 

U+0014          ^T        Device Control4 

U+0015          ^U       Negative acknowledge

U+0016          ^V       Synchronous idle 

U+0017          ^W      End of the transmission block 

U+0018          ^X        Cancel

U+0019          ^Y        End of medium

U+001A          ^Z        Substitute

U+0030          0          Numeric Digit zero

U+0031          1          NumericDigit one

U+0032          2          NumericDigit two

U+0033          3          NumericDigit three

U+0034          4          NumericDigit four

U+0035          5          NumericDigit five

U+0036          6          NumericDigit six

U+0037          7          NumericDigit seven

U+0038          8          NumericDigit eight

U+0039          9          NumericDigit nine

U+003A          :           Colon

U+003B          ;           Semicolon

U+003C          <          Less-than sign

U+003D          =          Equal/Equality sign

U+003E          >          Greaterthan sign

U+003F          ?          Question mark

Summary

In this tutorial, we tried to understand the meaning of the Unicode system in java. We saw its evolution, need, and usage. We understood the facts about this system. Further, we had a glimpse of certain Unicode values starting from 0.


Related Topics

Upcasting in Java

To know what is Upcasting in Java we should first equip ourselves about what is casting or type casting in Java. Casting The process of providing or replacing a reference variable of...

3 minutes read.

Java String trim() method

Java String trim() method returns String after eliminating leading and trailing spaces. Note:- Java String trim() method doesn't trim or omit middle spaces. Syntax: public String trim() Returns: It returns string with omitted leading and...

2 minutes read.

Creating API Document Javadoc tool

The JavaDoc utility is a document generator tool written in Java that generates standard documentation in HTML format. It parses declarations and documentation in a source file collection that describes...

3 minutes read.

Polygonal Number in Java

What does a Java Polygonal Number Mean? In mathematics, a polygonal number refers to a number that is expressed through dots or pebbles arranged in a regular polygonal pattern. Alphas are...

4 minutes read.

Java Integer longValue() method

The longValue()  method of Java Integer class returns a long value for this Integer after a widening primitive conversion. Syntax public long longValue() Parameters NA Specified by This method is specified by longValue in class Number Return...

1 minute read.

Timestamp Operation in Java

JDBC escape syntax is supported by Timestamp's formatting and parsing functions. Additionally, it adds support for fractional seconds values for SQL TIMESTAMP.java.util.Date is wrapped in a lightweight wrapper that enables...

3 minutes read.

Compile time vs Runtime in java

Introduction: This article will discuss compile time vs. runtime in java. Compile time and runtime are two programming terms utilized in software improvement. Compile time is when the source code is...

3 minutes read.

Bellman Ford Algorithm in Java

Numerous algorithms have been used in dynamic programming to determine the shortest path inside a graph. Among them are Floyd, all-pair shortest path problem, Breadth First Search, Depth First Search,...

6 minutes read.

Object class in Java

In Java, a class is a file containing the Java byte code. It can essentially specifically be executed on the JVM (Java Virtual Machine), fairly significant. The JVM mostly generally...

6 minutes read.

Root exception in java

Java: The main feature of java which is not in C or object oriented programming language is platform independence. Not only the platform independence there are many other features in java...

3 minutes read.

Best Java IDE

Applications for desktop, workplace, smartphone, and the internet can be created using Java, one of the most popular programming languages. Java will undoubtedly be a popular programming language for so...

5 minutes read.

Uses of Java

Java is used in many real-world Java applications, including technologies and tools. This Java programming language has become the backbone for developing many applications. In areas like embedded systems and...

3 minutes read.

Java String join() method

Java String join() method returns a joined String with given delimiter Syntax: public static String join(CharSequence delimeter,charSequence...elements) public static String join(CharSequence delimeter,Iterable<?extens charSequence>elements) Parameters: delimiter: char value to be added with each element elements: char value...

1 minute read.

Java DatagramSocket and Java DatagramPacket

Datagrams TCP/IP style networking specifies a serialized, predictable, and reliable stream of data in the form of a packet. Servers and clients communicate through a reliable channel, such as TCP socket, have a dedicated...

6 minutes read.

How to add 24 Hours to Date in Java?

In this tutorial, we will learn how to add 24 hours to the local or current date in Java language. We will begin our topic with basic concepts and would...

2 minutes read.

Java String Methods

Java String Methods Java String class is the most important class of the java.lang package. It is used to handle the String related operations. It contains a lot of built-in Java...

2 minutes read.

Java Integer numberOfLeadingZeros() method

The numberOfLeadingZeros()  method of Java Integer class returns the total number of zero bits preceding the highest-order one-bit in the 2’s complement binary representation of the specified int value.  Syntax public static...

1 minute read.

Difference between JIT and JVM in Java

In this tutorial, we will discuss the difference between JIT (Just In Time Compiler) and JVM (Java Virtual Machine) in Java. Before we move to the differences, let's understand what...

4 minutes read.

Java Do While Loop

When we wish to test the exit condition at the end of the loop, we use a do-while loop. The do-while loop always executes its body at least once, because...

1 minute read.

String to JSON in Java

Nowadays, receiving data in JSON String format rather than XML is quite frequent. Java does not transform JSON String to JSON Object when dealing with JSON String. However, using the...

3 minutes read.