8276 * @throws NullPointerException if {@code scriptName} is null
8277 */
8278 public static final UnicodeScript forName(String scriptName) {
8279 scriptName = scriptName.toUpperCase(Locale.ENGLISH);
8280 //.replace(' ', '_'));
8281 UnicodeScript sc = aliases.get(scriptName);
8282 if (sc != null)
8283 return sc;
8284 return valueOf(scriptName);
8285 }
8286 }
8287
8288 /**
8289 * The value of the {@code Character}.
8290 *
8291 * @serial
8292 */
8293 private final char value;
8294
8295 /** use serialVersionUID from JDK 1.0.2 for interoperability */
8296 private static final long serialVersionUID = 3786198910865385080L;
8297
8298 /**
8299 * Constructs a newly allocated {@code Character} object that
8300 * represents the specified {@code char} value.
8301 *
8302 * @param value the value to be represented by the
8303 * {@code Character} object.
8304 *
8305 * @deprecated
8306 * It is rarely appropriate to use this constructor. The static factory
8307 * {@link #valueOf(char)} is generally a better choice, as it is
8308 * likely to yield significantly better space and time performance.
8309 */
8310 @Deprecated(since="9")
8311 public Character(char value) {
8312 this.value = value;
8313 }
8314
8315 private static class CharacterCache {
|
8276 * @throws NullPointerException if {@code scriptName} is null
8277 */
8278 public static final UnicodeScript forName(String scriptName) {
8279 scriptName = scriptName.toUpperCase(Locale.ENGLISH);
8280 //.replace(' ', '_'));
8281 UnicodeScript sc = aliases.get(scriptName);
8282 if (sc != null)
8283 return sc;
8284 return valueOf(scriptName);
8285 }
8286 }
8287
8288 /**
8289 * The value of the {@code Character}.
8290 *
8291 * @serial
8292 */
8293 private final char value;
8294
8295 /** use serialVersionUID from JDK 1.0.2 for interoperability */
8296 @java.io.Serial
8297 private static final long serialVersionUID = 3786198910865385080L;
8298
8299 /**
8300 * Constructs a newly allocated {@code Character} object that
8301 * represents the specified {@code char} value.
8302 *
8303 * @param value the value to be represented by the
8304 * {@code Character} object.
8305 *
8306 * @deprecated
8307 * It is rarely appropriate to use this constructor. The static factory
8308 * {@link #valueOf(char)} is generally a better choice, as it is
8309 * likely to yield significantly better space and time performance.
8310 */
8311 @Deprecated(since="9")
8312 public Character(char value) {
8313 this.value = value;
8314 }
8315
8316 private static class CharacterCache {
|