Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

edu.emory.mathcs.util.* (147)

Package Samples:

edu.emory.mathcs.util.natives: Utility classes developed and/or maintained by the Distributed Computing Laboratory , Emory University.  
edu.emory.mathcs.util.classloader: Utility classes developed and/or maintained by the Distributed Computing Laboratory , Emory University.  
edu.emory.mathcs.util.swing: Utility classes developed and/or maintained by the Distributed Computing Laboratory , Emory University.  
edu.emory.mathcs.util.allocator: Utility classes developed and/or maintained by the Distributed Computing Laboratory , Emory University.  
edu.emory.mathcs.util.classloader.jar: Set of classes supporting dynamic class and resource loading and simplifying development of custom class loaders.  
edu.emory.mathcs.util.remote.server.impl: Utilities extending several traditional APIs to work across the network using RMI.  
edu.emory.mathcs.util.io.test: Utility classes related to stream-based I/O.  
edu.emory.mathcs.util.net.inproc: Networking-related utility classes.  
edu.emory.mathcs.util.security.auth: Security-related utilities.  
edu.emory.mathcs.util.security.action: Security-related utilities.  
edu.emory.mathcs.util.security.io: Security-related utilities.  
edu.emory.mathcs.util.remote.io.server: I/O streams over RMI.  
edu.emory.mathcs.util.security.auth.spi.passwd: Experimental.  
edu.emory.mathcs.util.concurrent
edu.emory.mathcs.util.remote.io
edu.emory.mathcs.util.remote.io.server.impl
edu.emory.mathcs.util.remote.server
edu.emory.mathcs.util.remote
edu.emory.mathcs.util.security
edu.emory.mathcs.util.security.auth.server

Classes:

PooledExecutor: A tunable, extensible thread pool class. The main supported public method is execute(Runnable command) , which can be called instead of directly creating threads to execute commands. Thread pools can be useful for several, usually intertwined reasons: To bound resource use. A limit can be placed on the maximum number of simultaneously executing threads. To manage concurrency levels. A targeted number of threads can be allowed to execute simultaneously. To manage a set of threads performing related tasks. To minimize overhead, by reusing previously constructed Thread objects rather than creating ...
CountDownLatch: A synchronization aid that allows one or more threads to wait until a set of operations being performed in other threads completes. A CountDownLatch is initialized with a given count . The await 55 methods block until the current count 55 reaches zero due to invocations of the countDown() 55 method, after which all waiting threads are released and any subsequent invocations of await 55 return immediately. This is a one-shot phenomenon -- the count cannot be reset. If you need a version that resets the count, consider using a CyclicBarrier . A CountDownLatch is a versatile synchronization tool and ...
HashIntMap: Hash table based implementation of the IntMap interface. This implementation provides all of the optional map operations, and permixts null values. This class makes no guarantees as to the order of the map; in particular, it does not guarantee that the order will remain constant over time. This implementation provides constant-time performance for the basic operations ( get and put ), assuming the hash function disperses the elements properly among the buckets. Iteration over collection views requires time proportional to the "capacity" of the HashMap instance (the number of buckets) plus its size ...
VolatileHashMap: A hashtable-based Map implementation with weak values . An entry in a VolatileHashMap will automatically be removed when its value is no longer in ordinary use. More precisely, the presence of a mapping to a given value will not prevent the value from being discarded by the garbage collector, that is, made finalizable, finalized, and then reclaimed. When a value has been discarded, all entries referring to it are effectively removed from the map. This class is a companion to java.util.WeakHashMap . Null values and the null key are supported. This class has performance characteristics similar to ...
Queue: A Collection designed for holding elements prior to processing. Besides basic java.util.Collection operations, queues provide additional insertion, extraction, and inspection operations. 0 * Queues typically, but do not necessarily, order elements in a FIFO (first-in-first-out) manner. Among the exceptions are priority queues, which order elements according to a supplied comparator, or the elements' natural ordering. Every Queue implementation must specify its ordering guarantees. The #offer(E) method adds an element if possible, otherwise returning false . This differs from the Collections#add(Object) ...
BlockingQueue: A java.util.Queue that additionally supports operations that wait for elements to exist when retrieving them, and wait for space to exist when putting them. BlockingQueues do not accept null elements. Implementations throw IllegalArgumentException on attempts to add , put or offer a null . A null is used as a sentinel value to indicate failure of poll operations. BlockingQueues may be capacity bounded. At any given time they may have a remainingCapacity beyond which no additional elements can be put without blocking. BlockingQueues without any intrinsic capacity constraints always report a remaining ...
PropertyUtils: Property and string manipulation and macro expansion utilities. Particularly useful in processing configuration files. Macros enable configuration files to refer to system properties, context-dependent information, etc. Macro expansion routine takes a string and resolves macro occurrences within that string against specified macro templates. Macro references have the following form: $macro_name{parameter}. Upon finding a macro reference, resolver finds macro template for macro_name and uses it to resolve parameter into a value string. For instance, empty macro name is associated by default with ...
ResourceLoader: This class aids in accessing remote resources referred by URLs. The URLs are resolved into resource handles which can be used to access the resources directly and uniformly, regardless of the URL type. The resource loader is particularly useful when dealing with resources fetched from JAR files. It maintains the cache of opened JAR files (so that so that subsequent requests for resources coming from the same base Jar file can be handled efficiently). It fully supports JAR class-path (references from a JAR file to other JAR files) and JAR index (JAR containing information about content of other ...
Executor: An object that executes submitted tasks. This interface provides a way of decoupling task submission from the mechanics of how each task will be run, including details of thread use, scheduling, etc. In the simplest case, an executor can run the submitted task immediately in the caller's thread: class DirectExecutor implements Executor { public void execute(Runnable r) { r.run(); } } However, tasks are typically executed in a different thread than the caller's thread. The executor below spawns a new thread for each task. class ThreadPerTaskExecutor implements Executor { public void execute(Runnable ...
PriorityQueue: An unbounded priority queue based on a priority heap. This queue orders elements according to an order specified at construction time, which is specified in the same manner as java.util.TreeSet and java.util.TreeMap : elements are ordered either according to their natural order (see java.lang.Comparable ), or according to a java.util.Comparator , depending on which constructor is used. The peek() 55 , poll() 55 , and remove(java.lang.Object) 55 methods return the minimal element with respect to the specified ordering. If multiple elements are tied for least value, no guarantees are made as to which ...
ThreadContext: Represents an immutable snapshot of a thread state. The state consists of delegatable thread locals, context class loader, and a priority. After the snapshot has been taken, it is later possible to execute tasks within that previously stored context using one of perform 55 methods. The thread executing the task need not be the same as the one for which the snapshot was originally taken; i.e. the state can be recovered (for the duration of the task) in any thread invoking "perform". This class is particularly useful in developing thread pools and asynchronous invocation frameworks, where it is common ...
TimeUnit: A TimeUnit represents time durations at a given unit of granularity and provides utility methods to convert across units, and to perform timing and delay operations in these units. TimeUnit is a "featherweight" class. It does not maintain time information, but only helps organize and use time representations that may be maintained separately across various contexts. The TimeUnit class cannot be directly instantiated. Use the SECONDS 55 , MILLISECONDS 55 , MICROSECONDS 55 , and NANOSECONDS 55 static instances that provide predefined units of precision. If you use these frequently, consider ...
URIClassLoader: Equivalent of java.net.URLClassloader but without bugs related to ill-formed URLs and with customizable JAR caching policy. The standard URLClassLoader accepts URLs containing spaces and other characters which are forbidden in the URI syntax, according to the RFC 2396. As a workaround to this problem, Java escapes and un-escapes URLs in various arbitrary places; however, this is inconsistent and leads to numerous problems with URLs referring to local files with spaces in the path. SUN acknowledges the problem, see but refuses to modify the behavior for compatibility reasons; see Java Bug Parade ...
PlainThreadFactory: Thread factory implementation that attempts to ensure that created threads are equivalent regardless of threads that request creation. Precisely, created threads belong to the same thread group, and they inherit a "parent thread context" (access control context, DelegatableThreadLocal s, etc.) from the factory creator rather than from the invoker of newThread(java.lang.Runnable) 55 . This thread factory is used as a default for PooledExecutor , as it guarantees deterministic behavior and minimal security properties. Nevertheless, stronger semantics are often neccessary in security-sensitive applications. ...
ConnectionPool: Manages a pool of socket connections to a single network endpoint. Pooling enables reusing connections for multiple, unrelated data transfers, and it can be used to implement certain connection-based protocols like HTTP 1.1. Additionally, pooling can aid in controlling network load - limiting the maximum pool size causes excessive connection requests to be enqueued at the client side. The endpoint is represented by a host name and a port number, as well as by an optional client socket factory, specified at the construction time. Client requests connections, use them, then return them to the pool. ...
AbstractIntMap: This class provides a skeletal implementation of the IntMap interface, to minimize the effort required to implement this interface. To implement an unmodifiable map, the programmer needs only to extend this class and provide an implementation for the entrySet method, which returns a set-view of the map's mappings. Typically, the returned set will, in turn, be implemented atop AbstractSet . This set should not support the add or remove methods, and its iterator should not support the remove method. To implement a modifiable map, the programmer must additionally override this class's put method (which ...
IntMap: An object that maps int keys to values. A map cannot contain duplicate keys; each key can map to at most one value. The IntMap interface provides three collection views , which allow a map's contents to be viewed as a collection of values, or set of key-value mappings. The order of a map is defined as the order in which the iterators on the map's collection views return their elements. Some map implementations, like the TreeIntMap class, make specific guarantees as to their order; others, like the HashIntMap class, do not. All general-purpose map implementation classes should provide two "standard" ...
CompressedOutputStream: Filter output stream that compresses data and features strong flush semantics. Data is written as gzipped packets of variable size. Flushing causes immediate ending of currently written packet and sending all the data off. Therefore, this stream can be used as a transport for RMI or RPC. Note that standard java.util.zip.ZipOutputStream and java.util.zip.GZipOutputStream are useless for this purpose due to their insufficiently strong flushing semantics: they don't guarantee that flush sends out all the data that was written so far, which leads to deadlocks in request-response-based protocols. Compression ...
Future: A Future represents the result of an asynchronous computation. Methods are provided to check if the computation is complete, to wait for its completion, and to retrieve the result of the computation. The result can only be retrieved when the computation has completed. The get method will block until the computation has completed. Once the computation has completed, the result cannot be changed, nor can the computation be restarted or cancelled. Sample Usage class Image { ... }; class ImageRenderer { Image render(byte[] raw); } class App { Executor executor = ... ImageRenderer renderer = ... void ...
CharStrings: Utility methods to securely manipulate on character arrays. The methods allow to treat the character arrays similarly to strings, yet they ensure that all temporary arrays are zeroed-out before discarding. Application of this class stems from the fact that String class is not appropriate for holding passwords and other sensitive information. Strings cannot be zeroed-out before unreferencing, thus the content may be dangling in memory for quite a while before it is garbage-collected, and it can stay in the process data block even longer, until it is overwritten. It has been demonstrated that attacker ...
GenericClassLoader: This class loader can be used to find class, resource and library handles as well as load classes, resources and libraries using abstract ResourceFinder entity encapsulating the searching approach. Resource handles allow accessing meta-information (like Attributes, Certificates etc.) related to classes, resources and libraries prior to loading them. GenericClassLoader is intended to be used as a base for custom class loaders. In most applications, GenericClassLoader can be used directly -- the application-specific functionality of resource searching can often be completely delegated to the resource ...
SecureAsyncTask: Variant of AsyncTask that overrides method createPerformer 55 so that it always runs with a fixed access control context and thread context inherited from the caller of createPerformer method. This class is intended primarily for subclassing. Typical usage scenario in subclasses is to create a new instance and call createPerformer . As a result, one obtains a runnable that will perform assigned task with the same access permissions, DelegatableThreadLocal s, and the context class loader, regardless of the thread that actually executes the runnable.
BufferedPipe: In-memory pipe that enables buffered sequential data transfer between threads. Pipe has two ends: source and sink. Source is an output stream into which the writer writes bytes. Sink is the input stream from which reader reads bytes. Data that was wrote to the source but not yet read from the sink are kept in a pipe buffer. This implementation features dynamic buffer sizing, so that memory consumption is minimized if there is little data to buffer. Buffer is upsized if more space is needed and downsized when data is read. Resizing never causes data copying. This implementation supports concurrent ...
ResourceHandle: This class represents a handle (a connection) to some resource, which may be a class, native library, text file, image, etc. Handles are returned by ResourceLoader 's get methods. Having the resource handle, in addition to accessing the resource data (using methods getInputStream() 55 or getBytes() 55 ) as well as access resource metadata, such as attributes, certificates, etc. As soon as the handle is no longer in use, it should be explicitly close() 55 d, similarly to I/O streams.
PoolingAllocator: Implements the Allocator using memory buffer pool. Able to enforce memory usage limits; attempts to avoid OutOfMemoryErrors by postponing the allocate requests when there is insufficient memory available in the system. Parameters of the pool are: (1) reserved capacity -- if the current memory usage of the pool is below this value, the allocate request will be always attempted without blocking; (2) maximum capacity -- if the allocate request would inflate the current memory usage above this value, the call will block until more memory is available; (3) security margin -- if the memory available ...

Home | Contact Us | Privacy Policy | Terms of Service