org.multiverse.transactional.refs
Class CharRef

java.lang.Object
  extended by org.multiverse.transactional.refs.CharRef

public class CharRef
extends java.lang.Object

A Ref for storing a char.

Author:
Peter Veentjer

Constructor Summary
CharRef()
           
CharRef(char value)
           
 
Method Summary
 void await(char desired)
           
 char awaitLargerOrEqualThan(char than)
           
 char awaitLargerThan(char than)
           
 char awaitNotEqualTo(char than)
           
 char awaitSmallerOrEqualThan(char than)
           
 char awaitSmallerThan(char than)
           
 char dec()
          Decreases the value by one.
 char dec(char amount)
          Decreases the value with the given amount.
 boolean equals(java.lang.Object thatObj)
           
 char get()
           
 int hashCode()
           
 char inc()
          Increases the value by one.
 char inc(char amount)
          Increases the value with the given amount.
 char set(char newValue)
          Sets the new value and returns the old value.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CharRef

public CharRef()

CharRef

public CharRef(char value)
Method Detail

get

public final char get()

await

public final void await(char desired)

awaitLargerThan

public final char awaitLargerThan(char than)

awaitLargerOrEqualThan

public final char awaitLargerOrEqualThan(char than)

awaitSmallerThan

public final char awaitSmallerThan(char than)

awaitSmallerOrEqualThan

public final char awaitSmallerOrEqualThan(char than)

awaitNotEqualTo

public final char awaitNotEqualTo(char than)

set

public final char set(char newValue)
Sets the new value and returns the old value.

Parameters:
newValue - the new value.
Returns:
the previous value.

inc

public final char inc()
Increases the value by one.

Returns:
the new value.

inc

public final char inc(char amount)
Increases the value with the given amount.

Parameters:
amount - the amount to increase with.
Returns:
the new value.

dec

public final char dec()
Decreases the value by one.

Returns:
the new value

dec

public final char dec(char amount)
Decreases the value with the given amount.

Parameters:
amount - the amount to decrease the value with.
Returns:
the new value.

toString

public final java.lang.String toString()
Overrides:
toString in class java.lang.Object

hashCode

public final int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public final boolean equals(java.lang.Object thatObj)
Overrides:
equals in class java.lang.Object


Copyright © 2008-2010 Multiverse. All Rights Reserved.