xbn.util
Class XBNLocked

java.lang.Object
  |
  +--xbn.XBNObject
        |
        +--xbn.util.XBNLocked
Direct Known Subclasses:
AOSLCreator, PrimitiveArray, UniqueString

public abstract class XBNLocked
extends XBNObject

The base class for all things implementing xbn.util.LockOneWay. Has standardized functions that throw LockedExceptions.

Source code:  XBNLocked.java.


Fields inherited from class xbn.XBNObject
bFALSE_IN_PRODUCTION, bTRUE_IN_PRODUCTION, sCNSTR, sES, sLINE_SEP
 
Constructor Summary
XBNLocked()
           
 
Method Summary
protected  void throwLX(String s_funcBody)
          Throw a LockedException.
protected  void throwLX(String s_callingFunc, String s_name, String s_lockedMsg)
          Throw a LockedException.
protected  void throwLXIfLocked(boolean b_locked, String s_callingFunc)
          If locked, throw a LockedException.
protected  void throwLXIfLocked(boolean b_locked, String s_callingFunc, String s_name)
          If locked, throw a LockedException.
protected  void throwLXIfLocked(boolean b_locked, String s_callingFunc, String s_name, String s_lockedMsg)
          If locked, throw a LockedException.
protected  void throwLXIfUnlocked(boolean b_locked, String s_callingFunc)
          If unlocked, throw a LockedException.
 
Methods inherited from class xbn.XBNObject
getXMsgPrefix, sop, sopl, sopl, throwAX, throwAXIfBadStr, throwAXIfNull, throwAXSpoof
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XBNLocked

public XBNLocked()
Method Detail

throwLX

protected final void throwLX(String s_funcBody)

Throw a LockedException.

Equal to throw new LockedException(getXMsgPrefix() + s_funcBody)

Parameters:
s_funcBody - The throwing function name and error message body.

throwLX

protected final void throwLX(String s_callingFunc,
                             String s_name,
                             String s_lockedMsg)

Throw a LockedException.

If s_name is not null, this equals throw new LockedException(getXMsgPrefix() + s_callingFunc + " [name=" + s_name + "]: " + s_lockedMsg))

If s_name is null, this equals throw new LockedException(getXMsgPrefix() + s_callingFunc + ": " + s_lockedMsg))


throwLXIfLocked

protected final void throwLXIfLocked(boolean b_locked,
                                     String s_callingFunc)

If locked, throw a LockedException. Otherwise, do nothing.

If b_locked then this equals throwLX(s_callingFunc + ": isLocked() equals true.")

Parameters:
b_locked - If true, then this class is locked. If false, it is not locked.
s_callingFunc - The name of the function that will throw this error.

throwLXIfLocked

protected final void throwLXIfLocked(boolean b_locked,
                                     String s_callingFunc,
                                     String s_name)

If locked, throw a LockedException. Otherwise, do nothing.

If b_locked then this equals throwLX(s_callingFunc, s_name, s_lockedMsg)


throwLXIfLocked

protected final void throwLXIfLocked(boolean b_locked,
                                     String s_callingFunc,
                                     String s_name,
                                     String s_lockedMsg)

If locked, throw a LockedException. Otherwise, do nothing.

If b_locked then this equals throwLX(s_callingFunc, s_name, s_lockedMsg)


throwLXIfUnlocked

protected final void throwLXIfUnlocked(boolean b_locked,
                                       String s_callingFunc)

If unlocked, throw a LockedException. Otherwise, do nothing.

If b_locked equals false, then this equals throwLX(s_callingFunc + ": isLocked() equals false.")

Parameters:
b_locked - If false, then this class is not locked. If true, it is locked.
s_callingFunc - The name of the function that will throw this error.



Copyright 1997-2003, Jeff Epstein, All Rights Reserved. See top of source code files for copyright notice.

 

http://sourceforge.net/projects/xbnjava

 

SourceForge.net Logo