xbn.array.primitive
Class LPAConfig

java.lang.Object
  |
  +--xbn.XBNObject
        |
        +--xbn.array.primitive.LPAConfig

public class LPAConfig
extends XBNObject

Configuration for a ListAOS.

Source code:  LPAConfig.java


Fields inherited from class xbn.XBNObject
bFALSE_IN_PRODUCTION, bTRUE_IN_PRODUCTION, sCNSTR, sES, sLINE_SEP
 
Constructor Summary
LPAConfig()
          Create an LPAConfig with default settings.
LPAConfig(boolean b_makeVisible)
          Create an LPAConfig.
LPAConfig(String s_divider)
          Create an LPAConfig.
LPAConfig(String s_divider, boolean b_makeVisible)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_postfix)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_postfix, boolean b_makeVisible)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_divider, String s_postfix)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_divider, String s_postfix, boolean b_makeVisible)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_divider, String s_postfix, String s_ifNull)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_divider, String s_postfix, String s_ifNull, String s_ifEmpty)
          Create an LPAConfig.
LPAConfig(String s_prefix, String s_divider, String s_postfix, String s_ifNull, String s_ifEmpty, boolean b_makeVisible)
          Create an LPAConfig.
 
Method Summary
 boolean doMakeVisible()
          Get the string that should precede the entire list.
 String getDivider()
          Get the string that should go between each item in the list.
 String getIfEmpty()
          Get the string that should be returned in the case that the object-to-be-listed has zero elements.
 String getIfNull()
          Get the string that should be returned in the case that the object-to-be-listed, as a whole, is null.
 String getPostfix()
          Get the string that should follow the entire list.
 String getPrefix()
          Get the string that should precede the entire list.
 
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

LPAConfig

public LPAConfig()

Create an LPAConfig with default settings.

Equal to LPAConfig("'", "'")


LPAConfig

public LPAConfig(String s_divider)

Create an LPAConfig.

Equal to LPAConfig(null, s_divider, null)


LPAConfig

public LPAConfig(String s_prefix,
                 String s_postfix)

Create an LPAConfig.

Equal to LPAConfig(s_prefix, s_postfix, false)


LPAConfig

public LPAConfig(String s_prefix,
                 String s_divider,
                 String s_postfix)

Create an LPAConfig.

Equal to LPAConfig(s_prefix, s_divider, s_postfix, false)


LPAConfig

public LPAConfig(boolean b_makeVisible)

Create an LPAConfig.

Equal to LPAConfig(null, null, b_makeVisible)


LPAConfig

public LPAConfig(String s_divider,
                 boolean b_makeVisible)

Create an LPAConfig.

Equal to LPAConfig(null, s_divider, null, b_makeVisible)


LPAConfig

public LPAConfig(String s_prefix,
                 String s_postfix,
                 boolean b_makeVisible)

Create an LPAConfig.

Equal to LPAConfig(s_prefix, ", ", s_postfix, b_makeVisible)


LPAConfig

public LPAConfig(String s_prefix,
                 String s_divider,
                 String s_postfix,
                 boolean b_makeVisible)

Create an LPAConfig.

Equal to LPAConfig(s_prefix, s_divider, s_postfix, null, "__ZERO_ELEMENTS__", b_makeVisible)


LPAConfig

public LPAConfig(String s_prefix,
                 String s_divider,
                 String s_postfix,
                 String s_ifNull)

Create an LPAConfig.

Equal to LPAConfig(s_prefix, s_divider, s_postfix, s_ifNull, "__ZERO_ELEMENTS__")


LPAConfig

public LPAConfig(String s_prefix,
                 String s_divider,
                 String s_postfix,
                 String s_ifNull,
                 String s_ifEmpty)

Create an LPAConfig.

Equal to LPAConfig(s_prefix, s_divider, s_postfix, s_ifNull, s_ifEmpty, false)


LPAConfig

public LPAConfig(String s_prefix,
                 String s_divider,
                 String s_postfix,
                 String s_ifNull,
                 String s_ifEmpty,
                 boolean b_makeVisible)

Create an LPAConfig.

Regarding s_prefix and s_postfix: If you do not want any value for the prefix or postfix, set it to null. You could set it to empty string, but null is quicker (with null, you do nothing...with empty string, you actually concatenate empty string onto the returned value).

Parameters:
s_prefix - What the (whole) returned string should start with. See getPrefix.
s_divider - What should go between each item. (This is the only item that) may not be null. See getDivider.
s_postfix - What the (whole) returned string should end with. See getPostfix.
s_ifNull - If the array of objects to list is null (as a whole), this is the string returned. See getIfNull.
s_ifEmpty - If the array of objects to list has no elements, this is the string returned. See getIfEmpty.
b_makeVisible - If true, then all items are made visible before being listed. See doMakeVisible.
Method Detail

getPrefix

public final String getPrefix()

Get the string that should precede the entire list.

Returns:
s_prefix Exactly as provided to the constructor.

getDivider

public final String getDivider()

Get the string that should go between each item in the list.

Returns:
s_divider Exactly as provided to the constructor.

getPostfix

public final String getPostfix()

Get the string that should follow the entire list.

Returns:
s_postfix Exactly as provided to the constructor.

getIfNull

public final String getIfNull()

Get the string that should be returned in the case that the object-to-be-listed, as a whole, is null.

Returns:
s_ifNull Exactly as provided to the constructor.

getIfEmpty

public final String getIfEmpty()

Get the string that should be returned in the case that the object-to-be-listed has zero elements.

Returns:
s_ifEmpty Exactly as provided to the constructor.

doMakeVisible

public final boolean doMakeVisible()

Get the string that should precede the entire list.

Returns:
b_makeVisible Exactly as provided to the constructor.



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