[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: RFC: Appreciation of .gmodel format (was deprecation)

From: Stefan Urbanek
Subject: Re: RFC: Appreciation of .gmodel format (was deprecation)
Date: Tue, 06 Jan 2004 19:54:58 +0100

On 2004-01-06 17:47:30 +0100 Alexander Malmberg <address@hidden> wrote:

Gregory John Casamento wrote:
--- Georg Fleischmann <address@hidden> wrote:


Writing a subclass of NSData (or, more appropriately, NSCoder) that
encodes as text is fairly easy, but also pointless. The resulting text
would be no more readable than the output of 'hexdump foo.gorm'. Eg. for
NSView, we have:

  [aCoder encodeRect: _frame];
  [aCoder encodeRect: _bounds];
  [aCoder encodeValueOfObjCType: @encode(BOOL) at:
  [aCoder encodeValueOfObjCType: @encode(BOOL)
                             at: &_is_rotated_or_scaled_from_base];
  [aCoder encodeValueOfObjCType: @encode(BOOL) at:
  [aCoder encodeValueOfObjCType: @encode(BOOL) at:
  [aCoder encodeValueOfObjCType: @encode(unsigned int) at:

so instead of a bit of binary data, you'd get something like "0.0 0.0
100.0 100.0 0.0 0.0 100.0 100.0 0 0 0 1 5" .... Sure, it's text, but
you'd go insane if you tried to edit it by hand. :)

I believe what Georg Fleischmann wants isn't just a text format, it's a
structured, human readable text format.

What about NSKeyedArchiver and NSKeyedUnarchiver? Are there any plans to 
imlpement those classes in GNUstep? They can definitely help in creating 
readable object dumps (using textual versions of those archivers).

Cocoa reference:

Btw. Apple docs about archiving are using keyed archiver as an example.

Stefan Urbanek

First they ignore you, then they laugh at you, then they fight you, then you 
- Mahatma Gandhi

reply via email to

[Prev in Thread] Current Thread [Next in Thread]