[Seaside] Re: WAFileLibrary and non-alphanumerics

Boris Popov boris at deepcovelabs.com
Tue Oct 16 18:23:49 UTC 2007

Mind you the whole class versus instance there seems a little arbitrary, we should just move it all one way it seems.


(Sent from a BlackBerry)

----- Original Message -----
From: Boris Popov
To: 'Seaside - general discussion' <seaside at lists.squeakfoundation.org>
Sent: Tue Oct 16 11:19:22 2007
Subject: WAFileLibrary and non-alphanumerics

In case anyone else comes across a case where filenames include non-alphanumeric characters like dashes and underscores, you'll notice they get stripped by default, which won't work very well with your style-sheets. I'd made the following three changes in my subclass of it, sacrificing readability a bit, but it's not like I ever look at selectors there anyway.

(class) asSelector: aFilename
 ^('hex' , aFilename asByteArray asHexString) asSymbol.

isFileSelector: aSymbol
	^aSymbol startsWith: 'hex'.

asFilename: aSelector
 ^(ByteArray fromHexString: (aSelector
					copyFrom: 4
					to: aSelector size)) asString.



DeepCove Labs Ltd.
4th floor 595 Howe Street
Vancouver, Canada V6C 2T5

boris at deepcovelabs.com


This email is intended only for the persons named in the message
header. Unless otherwise indicated, it contains information that is
private and confidential. If you have received it in error, please
notify the sender and delete the entire message including any

Thank you.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20071016/e876256e/attachment.htm

More information about the seaside mailing list