Keyword
By Tiationg Kho |
Keyword
- Access Modifiers
publicprotected- default (no keyword required)
private
- Non-Access Modifiers
staticfinalabstractsynchronizedvolatile
- Class-Related Keywords
- Object-Related Keywords
- Method-Related Keywords
- Control Flow Statements
forwhiledo whilecontinuebreakif, else if, elseswitch, case, default
- Exception Handling
try, catch, finallythrow (used to explicitly throw an exception)throws (used to declare that a method can throw exceptions)
- Primitive Types
- Boolean
boolean (1 bit in Theory) (Wrapper Class is Boolean)
- Character
char (16 bits) (Wrapper Class is Character)
- Integer
byte (8 bits) (Wrapper Class is Byte)short (16 bits) (Wrapper Class is Short)int (32 bits) (Wrapper Class is Integer)long (64 bits) (Wrapper Class is Long)
- Floating-Point
float (32 bits) (Wrapper Class is Float)double (64 bits) (Wrapper Class is Double)
- Package-Related Keywords
- Literals (not keywords)