Comments on: Blame Larry Wall https://quoderat.megginson.com/2005/02/04/blame-larry-wall/ Open information and technology. Mon, 07 Feb 2005 17:58:37 +0000 hourly 1 http://wordpress.com/ By: Brent Hendricks https://quoderat.megginson.com/2005/02/04/blame-larry-wall/#comment-31 Mon, 07 Feb 2005 17:58:37 +0000 /?p=10#comment-31 I’m not really a Java programmer, but couldn’t you reverse the order of the arguments and make the namespace URL optional? Then either of:


branch.setName("foo");
branch.setName("foo","http://www.example.org/ns");

would be legal

]]>
By: David Megginson https://quoderat.megginson.com/2005/02/04/blame-larry-wall/#comment-30 Fri, 04 Feb 2005 18:46:23 +0000 /?p=10#comment-30 That’s a good example, Bill — thanks. I thought about it (as well as separate getters and setters for the namespace URI and local part), and I agree that there are cases where those would be a good idea. Still, that approach adds the problem (for the easiest case) of dealing with two strings and passing them around. To be memory efficient, there would also have to be some kind of internalization facility for the pair.

]]>
By: Bill de hÓra https://quoderat.megginson.com/2005/02/04/blame-larry-wall/#comment-29 Fri, 04 Feb 2005 17:45:01 +0000 /?p=10#comment-29
String parts[2] = branch.getNamepair();
branch.setNamepair("foo", "http://www.example.org/ns");

]]>