logo       

[xstream-dev] [jira] Commented: (XSTR-55) Ability to alias an entire packag: msg#00012

java.xstream.devel

Subject: [xstream-dev] [jira] Commented: (XSTR-55) Ability to alias an entire package

The following comment has been added to this issue:

Author: Gr?gory Joseph
Created: Tue, 20 Jul 2004 3:05 PM
Body:
The previous patch isn't really satisfying me, because :
- it doesn't actually map a package name to a "shortcut" name, but to empty
string (ie, com.blah.bleh.SomeClass can not be aliased to "foo.SomeClass" but
only to SomeClass)
- it's based on startsWith and substring methods, which makes it a bit hairy -
and possibly not very safe - for the sake of aliasing
com.blah.bleh.bluh.SomeOtherClass to "bluh.SomeOtherClass"

I'm planning on submitting another patch that would
- allow actual aliasing of a package to a "prefix", but only A package and not
it's subpackages
- be based on full package name of a Class instead of just using startsWith on
Class.getName()

... I'll do that .. eventually.. when my pc resurects.

Please tell me what you think, anyway ;)

---------------------------------------------------------------------
View this comment:
http://jira.codehaus.org/browse/XSTR-55?page=comments#action_21970

---------------------------------------------------------------------
View the issue:
http://jira.codehaus.org/browse/XSTR-55

Here is an overview of the issue:
---------------------------------------------------------------------
Key: XSTR-55
Summary: Ability to alias an entire package
Type: Improvement

Status: Unassigned
Priority: Major

Original Estimate: Unknown
Time Spent: Unknown
Remaining: Unknown

Project: XStream
Components:
Core
Fix Fors:
1.1
Versions:
1.1

Assignee:
Reporter: Joe Walnes

Created: Thu, 6 May 2004 2:20 PM
Updated: Tue, 20 Jul 2004 3:05 PM

Description:
Rather than having to do:

xstream.alias("com.blah.mypackage.MyClass", "MyClass");
xstream.alias("com.blah.mypackage.YourClass", "YourClass");
xstream.alias("com.blah.mypackage.SheepClass", "SheepClass");

I'd like to be able to do:

xstream.aliasPackage("com.blah.mypackage");



---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise