how to use getclass without printing class code example Example: getting class name in java a.getClass().getName();