things.data
Class FlaggedString

java.lang.Object
  extended by things.data.FlaggedString

public class FlaggedString
extends java.lang.Object

A flagged string. The flags let us know if the string has certain attributes.

I'm thinking a more generic flaggable Data type would be better than this, but there really is no lightweight way to do so in java (the generic part). Since this was added to support a port of classes, brute force seemed to be the way to go.

Version:
1.0

Version History

EPG - Initial - 10 AUG 06
 
Author:
Erich P. Gatejen

Constructor Summary
FlaggedString(java.lang.String theData, boolean hasWhiteSpace, boolean hasQuotable)
          Create a flagged string.
 
Method Summary
 java.lang.String getString()
          Get the string.
 boolean hasQuotable()
          Does it have quotable?
 boolean hasWhiteSpace()
          Does it have whitespace?
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FlaggedString

public FlaggedString(java.lang.String theData,
                     boolean hasWhiteSpace,
                     boolean hasQuotable)
Create a flagged string.

Parameters:
theData - the string.
hasWhiteSpace - the string has whitespace.
hasQuotable - the string has quotable characters. (That is, you'll what to quote it for certain purposes.)
Method Detail

hasWhiteSpace

public boolean hasWhiteSpace()
Does it have whitespace?

Returns:
true if so.

hasQuotable

public boolean hasQuotable()
Does it have quotable?

Returns:
true if so.

getString

public java.lang.String getString()
Get the string.

Returns:
the string.


Things.