Package hudson.util
package hudson.util
Other miscellaneous utility code
-
ClassDescriptionDeprecated.AdaptedIterator<T,
U> Iterator
that adapts the values returned from another iterator.Deprecated.ImplementAdministrativeMonitor
directly instead.Provides the alternative text to be rendered in the UI.Each instance of this class represents a text that can be replaced byAlternativeUiTextProvider
.Represents a two dimensional area.Used to build up arguments for a process invocation.BufferedFileWriter
that supports atomic operations.Indicates a fatal boot problem, amongErrorObject
ByteArrayOutputStream
with access to its raw buffer.Deprecated.useString.CASE_INSENSITIVE_ORDER
directlyFilter that sets the character encoding to be used in parsing the request to avoid Non-ASCII characters garbled.Chart generation utility code around JFreeChart.Can be used as a graph label.Transparently coalesces chunks of a HTTP stream that uses Transfer-Encoding chunked.Implements HTTP chunking support.Explicitly sets theThread.setContextClassLoader(java.lang.ClassLoader)
for threads it creates to its own classloader.Used to build up an argument in the classpath format.Represents a clock difference.Color constants consistent with the Hudson color palette.Model object for dynamically filed combo box, which is really justArrayList<String>
Enumeration
that aggregates multipleEnumeration
s.Represents write-once read-many file that can be optionally compressed to save disk space.Consistent hash.Hashes an object to some value.List
-like implementation that has copy-on-write semantics.Converter
implementation for XStream.CopyOnWriteMap<K,V> Map
that has copy-on-write semantics.CopyOnWriteMap.Hash<K,V> CopyOnWriteMap
backed byHashMap
.CopyOnWriteMap.Tree<K,V> CopyOnWriteMap
backed byTreeMap
.Traverses a directed graph and if it contains any cycle, throw an exception.ThreadFactory
that creates daemon threads.BuildsCategoryDataset
.Hex-binary decoding stream.Works likeFilterOutputStream
except its performance problem.Persisted list ofDescribable
s with some operations specific toDescriptor
s.Converter
implementation for XStream.Deprecated.since 2008-08-15.DescriptorList<T extends Describable<T>>List ofDescriptor
s.Visits a directory and its contents and pass them to theFileVisitor
.Scans by filtering things out fromFileFilter
.Scans everything recursively.Scans by using Ant GLOB syntax.Makes sure that no other Hudson uses ourJENKINS_HOME
directory, to forestall the problem of running multiple instances of Hudson that point to the same data directory.Computes the string edit distance.Hex-binary encoding stream.Converter
for enums.Basis for error model objects.ThreadFactory
that creates a thread, which in turn displays a stack trace when it terminates unexpectedly.This class has been created to help makeAtomicFileWriter
hopefully more reliable in some corner cases.Visits files in a directory recursively.OutputStream
that blocksFlushProofOutputStream.flush()
method.Server-side code related to the<f:apply>
button.Corresponds to types declared in index.jsDeprecated.as of 1.294 UseFormValidation
as a return value in your check method.Deprecated.as of 1.305 UseFormValidation.validateBase64(String, boolean, boolean, String)
instead.Deprecated.as of 1.294.Checks if the given value is an URL to some Hudson's top page.Deprecated.as of 1.294 UseFormValidation.validateNonNegativeInteger(String)
Deprecated.as of 1.294 UseFormValidation.URLCheck
Deprecated.as of 1.294.Deprecated.as of 1.294.Deprecated.as of 1.294.Represents a failure in a form field doFillXYZ method.Represents the result of the form field validation.Builds up the check URL for the client-side JavaScript to call back.Performs an application-specific validation on the given file.Indicates the kind of result.Convenient base class for checking the validity of URLs.Function1<R,P1> Unary functiony=f(x)
.VariousFuture
implementations.A JFreeChart-generated graph that's bound to UI.FilterInputStream
that buffers the first N bytes to a byte array on the side.Up to XStream 1.3 the defaultStringConverter
in XStream usedString.intern()
, which stressed the (rather limited) PermGen space with a large XML file.Historical algorithms for decryptingSecret
s.VariousHttpResponse
implementations.Model object used to display the generic error when Jenkins start up fails fatally during initialization.Model object used to display "Jenkins is loading data".Model object used to display "Hudson is restarting".Model object used to display the error top page if we find out that the container is picking up its own Ant and that's not 1.7.Model object used to display the error top page if we find out that the container doesn't support servlet 2.4.Model object used to display the error top page if we find out that XStream is running in pure-java mode.Model object used to display the error top page if we find that we don't have enough permissions to run.Creates a proxy that traps every method call.Interceptor aroundInvocationHandler
.Deprecated.Just useIOException
, which since Java 6 supports a cause.Adds more to commons-io.VariosIterator
implementations.Remove duplicates from another iterator.Creates a filtered view of another iterator.Produces {A,B,C,D,E,F} from {{A,B},{C},{},{D,E,F}}.Indicates that Jenkins is interrupted during reload.Used to build up launch parameters for a Java virtual machine.KeyedDataStorage<T,P> Convenient base class for implementing data storage.Converts line endings of a string.Supported line ending types for conversionModel object of dynamically filled list box.TaskListener
which sends messages to aLogger
.ClassLoader
that masks a specified set of classes from its parent class loader.Generated localization support class.Wraps commons file-upload and handles a "multipart/form-data" form submission (that often includes file upload.)Thread factory that sets thread name so we know who is responsible for so many threads being created.Model object used to display the error top page if we couldn't create the home directory.This class implements X-axis label skipping algorithm to avoid drawing overlapping labels.Model object used to display the error top page if there appears to be no temporary directory.Deprecated.Concurrency primitive.PackedMap<K,V> Should persist like a regular map.Collection whose change is notified to the parent object for persistence.Converter
implementation for XStream.ServletFilter
that chains multipleFilter
s, provided by pluginsExtension point that defines more elaborate way of killing processes, such as sudo or pfexec, forProcessTree
.Allows extensions to veto killing processes.Describes the cause for a process killing veto.Represents a snapshot of the process tree of the current system.Represents a local process tree, where this JVM and the process tree run on the same system.Code that gets executed on the machine where theProcessTree.OSProcess
is local.Represents a process tree over a channel.Remoting interfaces ofProcessTree
.Encrypt/decrypt data by using a "session" key that only lasts for the duration of the server instance.Parses the query string of the URL into a key/value pair.Utility code for reflection.Various remoting operations related to diagnostics.Heap dump, exposable to URL via Stapler.Retrier<V>This class implements a process of doing some action repeatedly synchronously until it is performed successfully.Builder to create a Retrier object.LogHandler
that stores the log records into a ring buffer.CollectionConverter
that ignoresXStreamException
.CustomReflectionConverter
that handle errors more gracefully.Scrambles, but does not encrypt, text.GlorifiedString
that uses encryption in the persisted form, to avoid accidental exposure of a secret.Deprecated.useServiceLoader
instead.CategoryAxis
shifted to left to eliminate redundant space between area and the Y-axis.ModifiedStackedAreaRenderer
.WrapsInputStream
toResource
.TaskListener
that generates output into a single stream.XMLFilter
that checks the proper nesting of table related tags.TagCloud<T>Represents an order-preserving tag cloud where each keyword gets a weight and displayed according to their weight.Represents a text file.Deprecated.useTimeUnit
.Resolves variables to its value, while encapsulating how that resolution happens.VariableResolver
backed by aMap
.Union of multipleVariableResolver
.XStream
customized in various ways for Jenkins’ needs.Create a nestedConverterImpl
subclass that extends this class to run some callback code just after a type is unmarshalled by RobustReflectionConverter.Strongly inspired by https://github.com/x-stream/xstream/blob/61a00fa225dc99488013869b57b772af8e2fea03/xstream/src/java/com/thoughtworks/xstream/core/SecurityUtils.java#L25 and taking into account https://github.com/x-stream/xstream/issues/282 Once the related issue is fixed, we will be able to use the regular method from XStream.
TaskListener
directly