|
From: Frank V. C. <fr...@co...> - 2000-01-24 18:14:58
|
Jim Koontz wrote:
>
> "Frank V. Castellucci" wrote:
>
> > Joe Nelson wrote:
> > >
> > > > If we just use Unicode then we either have to use another library, or
> > > > create one. What we originally proposed was to abstract the interface
> > > > and then provide some means to let users (developers) adapt another
> > > > string implementation to our interface. This is more complex but allows
> > > >
> > > > 1. For CoreLinux++ we can implement classes that use the String
> > > > abstraction. This way we are confident (as much as can be) that the
> > > > developers choice of string implementation won't break us (see Adapter).
> > > >
> > > > 2. String implementations that haven't been developed yet to be use
> > > > later on (ditto Adapter).
> > > >
> > > > 3. Dynamic string changes in some cases (see Bridge).
> > >
> > > So corelinux++ is only aiming to be an interface, rather than provide
> > > any implementations?
> > >
> > > --Joe
> > >
> >
> > No, we need to at least provide a String derivation that works with
> > straight char.
> >
> > For example, lets drop to a implementation for discussion:
> >
> > AbstractString {abstract}
> > AbstractStringAdapter {abstract} isA Adapter, isAbstractString
> >
> > StringUtf8 isA AbstractStringAdapter and hasA std::string
> >
> > then StringUtf8 delegates to the string implementation when a
> > AbstractString method is invoked.
> >
> > Meanwhile, any of our other classes (libcorelinux++, libcoreframework++)
> > that use a string would use AbstractString and would work with whatever
> > string( char, wchar, Unicde, etc) was adapted to our interface.
> >
>
> I thought we could define the interface in AbstractString, and then create a
> CoreLinuxString using the std::string, and the Adapter. This would give us a
> functional string class, and provide an example for extension of the
> AbstractString into another string class (for use with Unicode or ISO/IEC
> 10646, etc.).
>
> Jim Koontz
> jrk...@us...
I think we said the same thing. Have you given anythough to what the
AbstractString thinks the character types are?
--
Frank V. Castellucci
http://corelinux.sourceforge.net
OOA/OOD/C++ Standards and Guidelines for Linux
|