Package org.apache.openjpa.lib.util
General Utilities
-
Interface Summary Interface Description Clearable Generic interface for components that can be cleared so that helpers can treat them in a generic way.Closeable Generic interface for components that can be closed so that helpers can treate them in a generic way.EventManager Basic event manager interface.ReferenceMap AMap
type that can hold its keys, values, or both with weak or soft references.SizedMap AMap
type that maintains a maximum size, automatically removing entries when the maximum is exceeded. -
Class Summary Class Description Base16Encoder Base 16 encoder.Bytes This class came from the Apache Commons Id sandbox project in support of the UUIDGenerator implementation.ClassUtil Various helper methods to deal with ClassesCodeFormat Encapsulates some common Java source code formatting options.Files Utility operations on files.FormatPreservingProperties A specialization ofProperties
that stores its contents in the same order and with the same formatting as was used to read the contents from an input stream.J2DoPrivHelper Helper class to obtain the Privilege(Exception)Action object to perform Java 2 doPrivilege security sensitive function call in the following methods: AccessibleObject.setAccessible Class.forName Class.getClassLoader Class.getDeclaredField Class.getDeclaredFields Class.getDeclaredMethod Class.getDeclaredMethods Class.getProtectionDomain Class.getResource Class.newInstance ClassLoader.getParent ClassLoader.getResource ClassLoader.getResources ClassLoader.getSystemClassLoader File.deleteOnExit File.delete File.exists File.getAbsoluteFile File.getAbsolutePath File.getCanonicalPath File.listFiles File.length File.isDirectory File.mkdirs File.renameTo File.toURL FileInputStream new FileOutputStream new System.getProperties InetAddress.getByName MultiClassLoader new ServerSocket new Socket new Socket.accept System.getProperty Thread.getContextClassLoader Thread.setContextClassLoader Thread new TemporaryClassLoader new URL.openStream URLConnection.getContent ZipFile new AnnotatedElement.getAnnotations AnnotatedElement.getDeclaredAnnotations AnnotatedElement.isAnnotationPresent jakarta.validation.Validator.validate jakarta.validation.Validation.buildDefaultValidatorFactory If these methods are used, the following sample usage patterns should be followed to ensure proper privilege is granted:JavaVersions Utilities for dealing with different Java specification versions.Localizer The Localizer provides convenient access to localized strings.Localizer.Message AMessage
can provide a localized message via theLocalizer.Message.getMessage()
method call, and can also provide the original key, package, and substitution array that were used to assemble the message.LRUMap Extension of the commonsLRUMap
that can change its maximum size.MultiClassLoader Class loader type that can be configured to delegate to multiple internal class loaders.Options A specialization of theProperties
map type with the added abilities to read application options from the command line and to use bean patterns to set an object's properties via command-line the stored mappings.OrderedMap<K,V> A Map with predictable iteration order.ParameterTemplate A template that allows parameter substitutions.ReferenceHashMap Map in which the key, value, or both may be weak/soft references.ReferenceHashSet A set whose values may be stored as weak or soft references.Services Utility classes to locate services, as defined in the Jar File Specification.SimpleRegex Allows for simple regex style testing of strings.StringDistance Utilities for calculating string distance.StringUtil TemporaryClassLoader ClassLoader implementation that allows classes to be temporarily loaded and then thrown away.TimestampHelper Helper base class attempts to return java.sql.Timestamp object with nanosecond precision.TypedProperties A specialization of theProperties
map type with added convenience methods to retrieve and set options as primitive values.UUIDGenerator UUID value generator. -
Enum Summary Enum Description JavaVendors Utilities for dealing with different Java vendors. -
Exception Summary Exception Description FormatPreservingProperties.DuplicateKeyException ParseException Exception type for parse errors. -
Annotation Types Summary Annotation Type Description Reflectable Annotates a getter method or field soreflection utility
to control whether the annotated member is recorded during scanning for bean-style method or field.