Package javolution37.javolution.lang
java.lang package or are not available for all platforms (including J2ME CLDC).See: Description
-
Interface Summary Interface Description Immutable This interface identifies classes whose instances are not subject or susceptible to change or variation after creation.Reference<T> This interface represents an object reference, the reachability level of a reference varies based on the actual reference implementation.Reusable This interfaces identifies mutable objects capable of being used again or repeatedly; oncereset, reusable objects behave as if they were brand-new. -
Class Summary Class Description CharSet This class represents a set of characters.ClassInitializer This utility class allows for initialization of all Java(tm) classes at startup to avoid initialization delays at an innapropriate time.MathLib This utility class ensures cross-platform portability of the math library.PersistentReference<T> This class represents a reference over an object which can be kept persistent accross multiple program executions.Reflection This utility class greatly facilitates the use of reflection to invoke constructors or methods which may or may not exist at runtime.Reflection.Constructor This class represents a run-time constructor obtained through reflection.Reflection.Method This class represents a run-time method obtained through reflection.Text This class represents an immutable character sequence with extremely fastconcatenation,insertionanddeletioncapabilities (O[Log(n)]) instead of O[n] for StringBuffer/StringBuilder).TextBuilder This class represents anAppendabletext whose capacity expands gently without incurring expensive resize/copy operations ever.TextFormat<T> This class represents the base format for text parsing and formatting; it supportsCharSequenceandAppendableinterfaces for greater flexibility.TextFormat.Cursor This class represents a parsing cursor.TypeFormat This class provides utility methods to parseCharSequenceinto primitive types and to format primitive types into anAppendable.
Package javolution37.javolution.lang Description
Provides fundamental classes and interfaces; some of which are either missing from
the java.lang package or are not available for all platforms (including J2ME CLDC).
For applications targetting the J2SE 5.0+ run-time (ant 1.5), the
Appendable and Enum classes are replaced with the java.lang
equivalent.
FAQ:
- I'm accumulating a large string, and all I want to do is
append to the end of the current string, which is the better class to use,
Text or TextBuilder? Bearing in mind that speed is important, but I also want
to conserve memory.
It all depends of the size of the text to append (the actual size of the document being appended has almost no impact in both cases).
If you append one character at a time or a small text then
TextBuilder.append(Object)is faster (the cost of copying the characters to the internal buffer is then negligeable and TextBuilder never resizes its internal arrays).If you append larger character sequences (the threshold might be around 20 characters) then
Text.concat(Text)is more efficient (it avoid character copies, but creates small nodes objects instead).
DMelt 3.0 © DataMelt by jWork.ORG