Class SafeLongArray<V>

    • Field Detail

      • f_lock

        protected final com.oracle.coherence.common.util.AutoLock<LongArray<V>> f_lock
        The lock to hold during read and write operations.
    • Constructor Detail

      • SafeLongArray

        public SafeLongArray()
        Construct a new SafeLongArray.
      • SafeLongArray

        public SafeLongArray​(LongArray<V> laDelegate)
        Construct a new SafeLongArray around the specified delegate.
        Parameters:
        laDelegate - the delegate long array, it is not safe to externally access this array
    • Method Detail

      • getLock

        public com.oracle.coherence.common.util.AutoLock<LongArray<V>> getLock()
        Return the lock used to protect this LongArray, with the unsafe delegate as its resource.

        Explicit usage of this lock is only necessary when performing multiple sequential operations against the LongArray which need to be "atomic".

        Returns:
        the lock