I'm +1 on adding these classes, but I wholeheartedly agree with Gary's
point below. The class described by Stephen is a StringHolder, and
nothing else ;)

>neil

--- Gary Gregory <[EMAIL PROTECTED]> wrote:
> The word "Mutable" seems to carry quite a bit of baggage from all
> POVs! :-)
> When I think MutableString, I think of a String I can /tweak/, for
> example:
> 
> new MutableString("A").put(1, 'B').toString() -> "B"
> 
> When I look at what Stephen calls a MutableString, I think more
> "StringHolder" or "StringWrapper" or "StringProxy", depending on what
> other
> functionality is hanging off that class, for example, events
> triggering when
> the held value changes.
> 
> Gary (with mutable opinions)
> :-P
> 
> > -----Original Message-----
> > From: Stephen Colebourne [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, December 11, 2003 12:05
> > To: Jakarta Commons Developers List
> > Subject: Re: [lang] Mutables [was new StringBuffer.. what to call
> it]
> > 
> > MutableXxx is a group of classes which has been mooted on various
> > occaisions. It implies a simple holder onject for immutable values
> like
> > int
> > and String. Last time I blocked it because I thought primitives was
> more
> > appropriate, but I've changed my mind and would now +1 a mutable
> > subpackage
> > in [lang].
> > 
> > public class MutableString
> >   private String str;
> >   public String getString() {return str;}
> >   public void setString(String str) {this.str = str;}
> > }
> > 
> > Stephen
> > 
> > ----- Original Message -----
> > From: "Ash .." <[EMAIL PROTECTED]>
> > > >BTW: MutableString is a bad name as it can imply a class that
> holds a
> > > >String
> > > and has a getString and setString method.
> > >
> > > >Stephen
> > >
> > > Can you tell us why the name MutableString implies it has a
> getString
> > and
> > > setString.
> > >
> > > And what do people think here of introducing a different term
> (say
> > Strand)
> > > for this concept as I discussed earlier (I paste that here, last
> time it
> > was
> > > buried under confusion due to a typo.)
> > >
> > > "
> > > Talking about name, I would add my opinion that while it might be
> > > nice to have a name for the replacer that is much like the
> replacee,
> > > (StringBuf) one might prefer a more descriptive name at the
> expense
> > > of this convenience: (***  MutableString).
> > >
> > > As a compromise between the two, the name Strand can be adopted
> (Str...
> > > thus near the original one + can be defined to represent a
> mutable
> > > string contrasted with "String" which, by virtue of the so-named
> > > class in the API, is immutable.)
> > > "
> > >
> > > Ash
> > >
> > >
> > >
> > > ---------------------------------------------
> > >
> > > Run, rabbit run.
> > > Dig that hole, forget the sun,
> > > And when at last the work is done
> > > Don't sit down it's time to dig another one.
> > >
> > > _________________________________________________________________
> > > Our best dial-up offer is back.  Get MSN Dial-up Internet Service
> for 6
> > > months @ $9.95/month now! http://join.msn.com/?page=dept/dialup
> > >
> > >
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > > For additional commands, e-mail:
> [EMAIL PROTECTED]
> > >
> > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to