NOTICE: This channel is no longer actively logged.
[00:01:16] <amcsi> so it's there forever and I shouldn't care, because primitive types use so less memory?[00:02:49] <dmlloyd> no, you're completely confused[00:02:50] *** kadams has quit IRC[00:03:11] *** arpu has joined ##java[00:03:46] <dmlloyd> maybe you should start out with C to learn about memory management :)[00:04:15] <pr3d4t0r> dmlloyd: See, this is why I think Java some times is harmful to humand life.[00:05:31] <dmlloyd> pr3d4t0r: nah. It just requires a certain minimum level of understanding. It's not Java's fault.[00:06:10] *** warriorforgod has joined ##java[00:07:00] *** rlubke has quit IRC[00:07:52] *** aksn has quit IRC[00:07:54] *** fenris has joined ##java[00:07:56] <fenris> hi[00:08:05] *** blahjake has quit IRC[00:08:06] *** zelnick has quit IRC[00:08:40] *** The_Birdman has quit IRC[00:09:27] <fenris> is there some "state-of-the-art" or upcoming gui framework for java besides swing and swt? something comparable to WTP from the .net world?[00:09:39] <fenris> erm[00:09:43] <fenris> i mean WPF[00:09:46] *** rlubke has joined ##java[00:10:00] *** bigjocker has quit IRC[00:10:35] <AMcBain> fenris: what's wrong with Swing :)[00:11:09] <tieTYT> http://radar.oreilly.com/2009/02/state-of-the-computer-book-mar-22.html[00:11:21] *** aleksei has joined ##java[00:11:49] *** tomaw has quit IRC[00:11:58] <tieTYT> java booksales going down[00:13:48] <reverend> thank god ruby madness is over[00:14:08] *** __simon__ has quit IRC[00:14:19] *** tomaw has joined ##java[00:15:14] <amcsi> dmlloyd: declaring a primitive type reserves a space in the memory, right?[00:15:15] <vol> RRRRRRRRRUUUUUUUUBBBBBBYYYYYYYY ON RAAAAIIIIIILLLLLLSSSS[00:15:25] <vol> amcsi: yes[00:15:26] <fenris> AMcBain: first, many people feel that it is "laggy"[00:15:27] <amcsi> or is it more complicated than that?[00:15:28] <dmlloyd> amcsi: no, not quite[00:15:34] <vol> depending on scope[00:15:43] <marvi> fenris: the sexy thing now is JavaFX. But it is not like WPF. More like Flex or Silverlight.[00:15:45] <vol> no? :o[00:15:47] <dmlloyd> if you have a local variable, it will reserve space on the stack for the duration of your execution[00:15:48] <AMcBain> fenris: many people don't kow how to use it properly.[00:16:02] <reverend> javafx is sexy? haha[00:16:23] <amcsi> I know that when it's done executing it removes everything from the memory[00:16:25] <dmlloyd> amcsi: if you have an instance field in an object class of a primitive type, it causes the object to be bigger by the size of that primitive field.[00:16:27] <marvi> reverend: sorry, forgot the irony markers.[00:16:42] <amcsi> but I thought of freeing up unnecessary memory usage during execution[00:16:57] <tieTYT> amcsi: why do you care?[00:16:57] <dmlloyd> amcsi: if you have a static field in an object class of a primitive type, the singular class instance will be bigger by the size of the primitive field.[00:17:23] *** FireSlash has joined ##java[00:17:24] <dmlloyd> amcsi: memory is freed automatically when objects go out of scope. You don't generally need to worry about it.[00:17:28] * r0bby smells premature optimization[00:17:30] <dmlloyd> that's what "garbage collection" is[00:17:40] <r0bby> and it needs to die a slow and painful death[00:17:55] *** bobbytek2 has joined ##java[00:18:35] <tieTYT> ugh, it's uncomfortable to me that in js every exit point doesn't need a return value[00:18:40] <amcsi> I kind of get it[00:18:44] <fenris> what i think is a pro for WPF is its declarative approach, and i would like to know if something similar exists in the java world[00:18:58] *** doc`` has joined ##java[00:19:55] <bobbytek2> groovy swing builder?[00:20:35] *** gregor_k has quit IRC[00:20:37] <marvi> fenris: Take a look at JavaFX[00:21:09] <tieTYT> aren't javafx and swing apples and oranges?[00:21:23] <bobbytek2> applets, not apples[00:21:26] <fenris> marvi: but this is not for desktop-applications, right?[00:22:19] <marvi> fenris: it can be deployed on desktop, yes.[00:22:51] <bobbytek2> marvi: good day to you fine sir[00:24:17] <marvi> fenris: http://www.learntechnology.net/content/javafx/javafx.jsp <-- CRUD app. Looks like shit, but you get the idea...[00:24:20] <aleksei> tieTYT: javafx for designers, java swing for programmers[00:24:43] *** ahughes has joined ##java[00:25:16] *** aksn has joined ##java[00:25:31] <aleksei> I've never understood that.. what's superior in javafx compared to swing, besides the fact it's targeted to designers??[00:25:42] <bobbytek2> yes, looks like shit indeedly[00:26:44] <fenris> ack[00:27:16] <reverend> my favorite thing about java graphics stuff is that i don't have to work with it. ever.[00:27:25] <amcsi> thank you[00:27:25] <amcsi> bye[00:27:26] *** amcsi has quit IRC[00:29:18] <fenris> yes, i am a backend guy myself... unfortunatly, in our company we want to switch our platform away from native win32, and we are evaluating .net and java[00:29:53] *** TryNiX has joined ##java[00:30:01] <fenris> and our company also develops gui-apps, so i need some pro-java-arguments[00:30:10] <fenris> related to guis[00:30:28] <TryNiX> Hi all, I am trying to switch a color and check what color it matches but I get error that case expression must be constant, any idea of a workaround? switch(c.getRGB()){[00:30:31] <TryNiX> case Color.black.getRGB(): return "black"; break;[00:30:53] <marvi> aleksei: JavaFX is several things. It is stuff added to the platform to simplify animations and stuff. It is a declarative language to create UI:s. It is tool support for Adobe CS. It is a new Java plugin for the browser.[00:31:56] *** tylo_ has quit IRC[00:32:16] *** ilaggoodly has quit IRC[00:32:45] *** ilaggoodly has joined ##java[00:32:47] <vol> TryNiX: that's correct. You can always get the RGB values of black, etc beforehand, and then check those[00:33:03] *** codethief has quit IRC[00:33:13] <vol> final blackRGB = Color.black.getRGB(); switch(c.getRGB()) { case blackRGB: ... }[00:33:15] <vol> that might work[00:33:44] <TryNiX> vol: ah ok, but I guess there is no way to check inline without having to define beforehand?[00:34:18] <vol> yeah, while Color.black might be constant, the return from the method isn't (for the compiler)[00:34:53] <TryNiX> alright, thanks alot :[00:34:54] <TryNiX> :)[00:37:04] *** untouchable has quit IRC[00:37:37] *** delskorch has joined ##java[00:41:18] *** redrebel has quit IRC[00:42:10] <svm_invictvs> hm....[00:42:12] *** delskorch has quit IRC[00:42:16] <svm_invictvs> So when it comes to Wicket...[00:42:37] <svm_invictvs> The front end stuff is all just regular old HTML, right?[00:43:29] *** l2trace99 has joined ##java[00:43:46] *** delskorch has joined ##java[00:44:39] *** poseidon has quit IRC[00:44:45] <l2trace99> can someone point me to a link that explains how to do convert a 14 char string into a date object ?[00:45:08] <svm_invictvs> ~~ l2trace99 javadoc SimpleDateFormat[00:45:09] <javabot> l2trace99: http://is.gd/igcb [java.text.SimpleDateFormat][00:45:11] *** Bonix has joined ##java[00:45:38] *** Odin79 has joined ##java[00:47:41] *** eidolon has joined ##java[00:48:47] *** HexKey has quit IRC[00:52:21] *** christo_m has joined ##java[00:52:35] <r0bby> l2trace99: google?[00:52:38] *** idea4good has quit IRC[00:52:41] <r0bby> seriously[00:52:47] <christo_m> whats the best way to check the formatting of a text file, say i want vectors to be formatted like (3,4,5.3,5) etc[00:52:51] <christo_m> on separate lines[00:52:58] <l2trace99> i didn't think i could use it in GWT[00:53:03] <christo_m> the problem with my current method is that i dont kno what to do with floats[00:53:36] *** wolfe has joined ##java[00:53:40] <r0bby> l2trace99: isn't your backend java?[00:53:47] * wolfe yawns[00:53:48] <christo_m> http://pastebin.com/m2b7e5676[00:54:18] <christo_m> thats my current code, dont mind the components variable im gonna remove that soon, i have a better idea to keep track of the number of them[00:54:18] <svm_invictvs> christo_m: why?[00:54:26] <christo_m> svm_invictvs: why what?[00:54:29] <r0bby> ~~ christo_m javadoc Float.parseFloat(*)[00:54:32] <l2trace99> java to javascript and I am pulling it from the sqlite db from gears[00:54:32] <javabot> christo_m: http://is.gd/jeim [java.lang.Float.parseFloat(String)][00:54:33] *** systat has quit IRC[00:54:36] <wolfe> what is the maximum number of parameters for a constructor method?[00:54:44] <tieTYT> wolfe: 4[00:54:44] <svm_invictvs> christo_m: Why are floats a problem.[00:54:49] <svm_invictvs> christo_m: also, look at string.split.[00:54:56] <l2trace99> so i was looking for alt ways[00:54:57] <wolfe> tieTYT: I'm pretty sure its more than 4 ;)[00:55:01] <reverend> wolfe: if you actually have to ask, you need to rethink whatever you're doing[00:55:10] <wolfe> reverend: uhhh, not my software.[00:55:17] <l2trace99> but SDF may work w/ GWT[00:55:21] <reverend> uhhh, then why do you care?[00:55:29] *** otep has quit IRC[00:55:39] <wolfe> reverend: WaveMaker has this "import database" feature which turns the data columns from a RDBMS to a java class file[00:55:49] <wolfe> I hit the paramter limit :)[00:55:52] <reverend> haha[00:55:58] <christo_m> svm_invictvs: so for my clarification, if i had (3, 4, 4.6, 5) etc[00:56:02] *** BeholdMyGlory has quit IRC[00:56:06] * r0bby slaps l2trace99[00:56:07] <wolfe> I did NOT design this stupid database I'm trying to import[00:56:08] <christo_m> i can use string split to make 4 different strings[00:56:09] <svm_invictvs> reverend: Not necessairly with autogenerated code...[00:56:13] <r0bby> http://www.google.com/search?q=GWT+date+format[00:56:15] <christo_m> each containing the information between the commas[00:56:22] <christo_m> given that i regex to match the commas right?[00:56:30] <reverend> svm_invictvs: people who use autogenerated code deserve what they get[00:56:39] <wolfe> heh[00:56:40] <r0bby> christo_m: short of regexp[00:56:46] <christo_m> r0bby: pardon?[00:56:56] <svm_invictvs> reverend: *shrug* ain't nothing wrong with autogenerated code. Assuming that the generating program is well tested.[00:57:01] <wolfe> its an application designer, its the only reasonable method[00:57:03] <r0bby> use Float.parseFloat() and catch NumberFormatException[00:57:15] <reverend> svm_invictvs: ain't nothing wrong with code i generate myself, with my own code[00:57:18] <wolfe> however like this example, it obvioiusly wont work right :)[00:57:20] <reverend> the rest is a pile of shit[00:57:37] <reverend> ~tech support[00:57:37] <svm_invictvs> wolfe: I'd look at tthe JLS[00:57:37] <javabot> Hello, ##java is not a technical support channel for your Java apps or virtual machines, it is a development enthusiast channel which prefers to receive questions and discussion on the topic of programming with the Java language. Please consider seeking help with the vendor of your software if you can't figure out how to use it.[00:57:38] <christo_m> r0bby: thats when i want to parse it for use in my algo im aware of this[00:57:52] <christo_m> r0bby: i first need to extract the data tho[00:57:54] <svm_invictvs> reverend: who was taht directed at?[00:57:58] <christo_m> and i see string split gives me an array[00:58:01] <wolfe> svm_invictvs: I will after I exhaust words with google :)[00:58:10] <reverend> wolfe[00:58:15] <r0bby> christo_m: yup it does it gives you String array[00:58:16] <svm_invictvs> wolfe: The jls is really easy to read.[00:58:34] <marvi> Google is lying. JLS tells the Truth.[00:58:40] <svm_invictvs> r0bby: Just strip out the parens, split by "," then parse each string with Float.parseFloat[00:58:44] <reverend> google is obviously more authoritative than the specification that describes the java language in detail, god[00:58:46] <svm_invictvs> er, not r0bby, christo_m[00:58:55] <svm_invictvs> sorry r0bby[00:59:55] *** Level1 has joined ##java[01:00:15] <wolfe> btw, it isn't this specific application, it is hibernate :)[01:00:20] <wolfe> hbm2java[01:00:23] <wolfe> for the whole PJO thing[01:00:27] <wolfe> *POJO[01:00:53] <reverend> watever you're doing could probably be easily written in several lines of clever perl[01:01:11] <marvi> Since when was Hibernate part of the Java platform? I didn't get the memo![01:01:17] <wolfe> it's not[01:01:29] <wolfe> its part of a development toolkit/IDE called wavemaker ;)[01:01:31] <christo_m> svm_invictvs: line.split("[\\,]")[01:01:42] <christo_m> is that the right regex to split at the commas?[01:01:43] <marvi> My irony isn't working today.[01:01:57] <svm_invictvs> christo_m: I think you can just split on ","[01:02:06] <sproingie> low irony makes jokes anemic[01:02:25] <christo_m> svm_invictvs: btw how would you strip the parens?[01:02:29] <reverend> christo_m: there's no need to put that in a character class and there's certainly no reason to eascape it[01:02:37] <r0bby> I don't think , is a metacharacter[01:02:43] <reverend> in or out of a character class[01:02:44] <r0bby> you only have to double escape metacharacters[01:02:47] *** l2trace99 has left ##java[01:02:54] *** mheld has joined ##java[01:02:58] <mheld> hey y'all[01:02:58] <svm_invictvs> christo_m: str = str.replace( "(", "").replace(")","") or something.[01:03:53] *** nijm has quit IRC[01:04:43] <mheld> how would I have a class header for a generic extend two interfaces?[01:04:46] <mheld> public interface ILo<T implements Traversal<T> extends IChange<T>> ?[01:05:15] <mheld> or would I have to implement the interface in a different interface[01:06:37] <mheld> ah, figured it out[01:06:48] <mheld> public interface ILo<T extends Traversal<T> & IChange<T>>[01:07:09] <mheld> did not know you could use an ampersand in a header[01:08:29] *** amz has joined ##java[01:08:39] <tieTYT> I work at a company with multiple apps and they all share a jar in a separate project. If a change needs to happen in that jar, I make it, I run this task called "publish local", I run a task called "resolve" in the project I'm working on and then I do a build. Is there a better way?[01:08:41] <svm_invictvs> mheld: You can't do taht. You need it to extend both classes?[01:09:04] <svm_invictvs> tieTYT: Use Ivy or maven?[01:09:12] <tieTYT> i do use ivy[01:09:28] <tieTYT> that's what those tasks are using[01:10:09] <mheld> svm_invictvs: it works[01:10:19] <mheld> you can't extend more than one class, can you?[01:10:19] <svm_invictvs> melter: Hm...[01:10:29] <mheld> you're implementing it[01:10:29] <mheld> but[01:10:31] <svm_invictvs> You can exten a class and implement any number of interfaces.[01:11:38] *** TryNiX has quit IRC[01:12:13] <svm_invictvs> mheld: I didn't know you could use & in generics...[01:12:15] <svm_invictvs> ~generics[01:12:15] <javabot> For a tutorial on generics, please see http://javachannel.net/wiki/pmwiki.php/Main/Generics[01:12:38] <Sou|cutter> svm_invictvs: yeah, one of those crazy things that people never use ;)[01:12:39] *** veleno has quit IRC[01:12:44] <Sou|cutter> it's scary![01:12:57] <svm_invictvs> What does it mean?[01:13:02] <tieTYT> except ricky clarkson[01:13:25] <tieTYT> it means you're going to get punched in the face by another maintainer[01:15:06] *** isr` has joined ##java[01:15:31] <svm_invictvs> meh[01:15:36] <svm_invictvs> Is |?[01:15:39] *** aksn has quit IRC[01:15:48] <isr`> howdie.[01:17:30] <svm_invictvs> hai[01:18:51] *** kane77 has quit IRC[01:18:54] <svm_invictvs> Is "hai" considered aolbonics?[01:21:29] *** mheld has left ##java[01:21:52] <tieTYT> in intellij, is there a shortcut to putting the file's name in my clipboard?[01:23:05] *** pstickne has joined ##java[01:23:19] <r0bby> svm_invictvs: it's worse[01:23:21] <svm_invictvs> copy path?[01:23:35] <svm_invictvs> r0bby: What's "worse"?[01:23:48] <cheeser> tieTYT: yeah. copy path[01:24:05] <tieTYT> cheeser: that's a little different although helpful. Is tehre anyway to just get the file name?[01:24:16] *** Hink has quit IRC[01:24:24] <cheeser> without the path?[01:24:28] <tieTYT> yep[01:24:37] <cheeser> just "copy" then add .java[01:24:38] <cheeser> 8^)=[01:24:58] <tieTYT> that's 2 steps. Not the idea way[01:25:07] <tieTYT> yeah that's what i do now[01:25:55] <svm_invictvs> Can Eclipse do that?[01:25:57] <svm_invictvs> :P[01:26:00] <tieTYT> i donno[01:26:14] <tieTYT> i was thinking about how I haven't used anything but intellij for so long that I don't know what the feature gap is[01:26:15] <svm_invictvs> BUT MAYBE THERE'S A PLUGIN HAR HAR[01:26:35] <svm_invictvs> now guffaw from the whole room?[01:27:18] *** cmccormick has quit IRC[01:28:37] *** HeatHawk[AP2] has quit IRC[01:29:35] *** cyth has quit IRC[01:30:30] *** smoog has quit IRC[01:31:23] *** NiallC has joined ##java[01:31:38] <tieTYT> this moron at my job is creating this library for us to use[01:31:52] <r0bby> Not Invented Here thing?[01:31:58] *** HeatHawk[AP2] has joined ##java[01:31:59] <tieTYT> they're not using it themselves and for some political reason won't let us modify it without getting an ok[01:32:01] *** smoog has joined ##java[01:32:21] <tieTYT> i've yet to get an ok for the bugs i've found that can be fixed[01:32:23] <AMcBain> tieTYT: sounds like they're morons[01:32:29] <unlord> is there some way to do -Djava.library.path=<asdf> in an ant build file?[01:32:31] <tieTYT> completely[01:32:34] <r0bby> poor self eseteem[01:32:46] <tieTYT> and yet my coworkers understand this person's attitude[01:32:48] <tieTYT> "it's her baby"[01:32:56] <AMcBain> ouch[01:33:01] <r0bby> so?[01:33:10] <r0bby> you fucked up, other developers want to help[01:33:13] <r0bby> let them fucking help[01:33:28] <r0bby> technically it belongs to the company[01:33:33] <AMcBain> I'd be happy to let people contribute if it was for the greater good ... I also wouldn't force anyone to use something stupid that won' really help either! :P[01:33:36] <tieTYT> not even "so". That's just plain wrong. It doesn't say "copyright: moron 2009" on it. It's owned by the company on the company's dime and 7 peopel are held up because she won't let us make fixes[01:33:45] <tieTYT> brb[01:33:52] *** teralaser has quit IRC[01:34:10] <AMcBain> he keeps trying, we're all immune.[01:35:06] <r0bby> tieTYT: just do it[01:35:07] *** aep has joined ##java[01:35:10] <aep> hi[01:35:18] <r0bby> "hey look it works"[01:35:22] <aep> in java all functions are "virtual" right?[01:35:54] <aep> means A a=new B will always behave like B (assumed B is a subclass of A)[01:36:27] <r0bby> aep: pick up a java book[01:36:44] <aep> i'm not intending to learn java[01:36:53] <AMcBain> then you have a problem.[01:37:03] <aep> i do?[01:37:26] <r0bby> aep: we're not here to teach somebody who can't be bothered to lear[01:37:28] <r0bby> learn[01:37:44] <aep> *yawn*[01:37:46] <aep> get over it[01:37:52] <r0bby> aep: No, YOU get over it[01:37:57] <aep> over what?[01:38:00] <r0bby> ~~ aep bibles[01:38:01] <javabot> Get these: 1) Sun Java Tutorial (http://java.sun.com/docs/books/tutorial) 2) Bruce Eckel's "Thinking in Java" (http://www.mindview.net/Books/TIJ) (Get the 3rd edition, the 4th is only freely available up to chapter 7.)[01:38:07] <r0bby> There's where to get help[01:38:23] <r0bby> also consult el google (http://www.google.com) before asking[01:38:32] *** aep has left ##java[01:38:43] <AMcBain> what a poor sport.[01:38:47] <r0bby> WOW[01:38:51] <r0bby> somebody expected him to try[01:38:52] <AMcBain> could have at least played along.[01:38:53] <r0bby> *SHOCK*[01:41:09] *** skoskav has quit IRC[01:41:10] *** bitcrave has quit IRC[01:41:33] *** otep has joined ##java[01:42:15] <svm_invictvs> aep: Its' the opposite of C++. IN C++ you explicitly make methods "virtual" and in java you can mark them as final. If you mark them as final at the basemost class it's effectively the C++ equivalent of a non-virtual member function.[01:42:34] <svm_invictvs> And C++ has no concept of finality[01:42:43] <AMcBain> aep left[01:42:51] <svm_invictvs> oh, yeah[01:42:54] <svm_invictvs> he's a regular in ##C++[01:43:15] <AMcBain> yeah, well, he decided to come hear and not want to work for it :P[01:43:31] <gjvc> here[01:43:56] *** TranceControl has quit IRC[01:45:44] *** Daniel_H has joined ##java[01:46:15] <Level1> hi, if I have a socket that is getting some data, how do I know when the remote computer is done sending data, as opposed to simply waiting for more data to be available?[01:46:36] <gjvc> you don't[01:46:51] <svm_invictvs> AMcBain: Well, I answered his question in C++ and got yelled at for being offtopic.[01:46:56] <AMcBain> heh[01:47:05] <AMcBain> yup. unless the other computer [is in your control and] sends a "done" signal.[01:47:13] <AMcBain> ^ Level1[01:47:28] <Zharf> if the protocol defines some sort of done siggnalwsignal[01:47:31] *** Razec has joined ##java[01:47:31] <Zharf> bah[01:47:31] <AMcBain> svm_invictvs: sad that most channels are quick to "hey, you, get on topic!"[01:47:34] <Zharf> stupid lag[01:47:58] <svm_invictvs> The remote coudl just close the socket and you'd likely get an eof[01:48:00] <Level1> AMcBain, well, the remote computer is a webbrowser... i don't seem how its possible to write a webserver since the browser doesn't send a done signal[01:48:48] <svm_invictvs> Level1: The server just sends the data that the browser requests. IT doesn't care what the browser does with it.[01:48:50] <AMcBain> yeah, the eof sounds like a plausible item. also, if it's a XML http request and such, those are well defined, etc.[01:49:54] <r0bby> ohh he's funny[01:50:06] <r0bby> he's bitching in ##c++ about how he doesn't wanna actually learn java[01:50:22] <dmlloyd> http://dmlloyd.blogspot.com/2009/02/class-local-data.html[01:50:39] *** Sulis has quit IRC[01:50:40] <AMcBain> gee. there's only like *one* business in the world that uses Java, and nobody /cares/ about them![01:51:10] <gjvc> wtf are you talking about?[01:51:18] <Level1> so, how do I detected an eof?[01:51:20] <AMcBain> aep[01:51:33] <svm_invictvs> AMcBain: hm[01:51:52] <r0bby> gjvc: a dumbass[01:52:10] <gjvc> r0bby, ok[01:52:32] <Level1> svm_invictvs, you have it backwards. The browser is sending the requests, the java that I have written handles it[01:53:02] <svm_invictvs> "Level1: The server just sends the data that the browser requests. IT doesn't care what the browser does with it."[01:53:06] <r0bby> okay yeh he is a dumbass[01:53:39] *** magcius has quit IRC[01:53:43] <Level1> "svm_invictvs, you have it backwards. The browser is sending the requests, the java that I have written handles it"[01:54:16] <Level1> svm_invictvs, what I'm saying is that the server can't detect when the browser is done sending. I want to be able to detect that[01:54:19] *** Sirisian has joined ##java[01:54:42] <svm_invictvs> oh[01:54:52] *** TryNiX has joined ##java[01:55:06] <TryNiX> what's a good font to print the code in (from Word)[01:55:07] <svm_invictvs> The HTTP protocol defines this.[01:55:23] <gjvc> TryNiX, Consolas 11 point[01:55:42] <Level1> svm_invictvs, really?[01:55:44] <TryNiX> gjvc: cheers :)[01:55:52] <Level1> svm_invictvs, how do I do it then?[01:56:23] <r0bby> I seriously can't stand people who act like elitists -- "My language is better than yours -- i REFUSE to learn yours!"[01:56:29] <svm_invictvs> Level1: I think, but I'm not 100% sure that an HTTP requestis something like....[01:56:29] <svm_invictvs> HTTP1.1 GET file.html CRLF[01:56:29] <svm_invictvs> CRLF[01:56:47] <gjvc> TryNiX, 99% of microsoft fonts are shite. i love fonts. i hope you enjoy consolas[01:56:57] <svm_invictvs> And once you receive a blank line you know that the request is finished[01:57:08] <Level1> svm_invictvs, so, two consectutive newlines idicates eof? okay, great![01:57:11] <TryNiX> gjvc: Consolas seem awesome :) thanks alot![01:57:27] <svm_invictvs> Level1: http://www.w3.org/Protocols/rfc2616/rfc2616.html[01:57:36] <gjvc> TryNiX, i assume you have ClearType enabled :)[01:57:47] <svm_invictvs> Level1: It ahs been *years* since I have done this, so read the RFC[01:58:02] *** Varox has quit IRC[01:59:38] *** marvi has quit IRC[01:59:49] *** Dr_Link has joined ##java[02:01:04] *** Sirisian has left ##java[02:01:05] <_W_> yes, svm_invictvs is wrong, and so is Level1[02:01:29] <_W_> nevermind, that was redundant after the link to the actual RFC[02:01:29] <svm_invictvs> _W_: Which is why i said read the RFC[02:01:39] <Level1> _W_, huh? Well, his advice seems to be working[02:02:02] *** orgy` has quit IRC[02:02:10] <svm_invictvs> Read teh RFC, I dont' remember HTTP well enough, tho[02:02:29] <svm_invictvs> RFCs are pretty easy to read and understand[02:03:03] <Level1> svm_invictvs, I'll read the RFC, but i think that the browser sends a blank line before the request string in a post request... thats a problem[02:03:10] <_W_> even better is not reading the spec, but using third party libraries that handles this[02:03:27] <svm_invictvs> dozens of the exist[02:03:39] <_W_> indeed[02:03:59] <_W_> up to and including fully fledged embedded servlet containers[02:03:59] <svm_invictvs> I had to write a web server for a class in college[02:04:04] <svm_invictvs> jetty...[02:04:16] *** sukuri has joined ##java[02:05:27] <_W_> svm_invictvs: showing how class assignments are usually silly[02:05:30] <gjvc> jetty == gay[02:05:54] <kaineo> can anyone help me out with my deck shuffle algorthm in java?[02:06:05] *** sukuri has left ##java[02:06:26] <cheeser> ~~ kaineo javadoc Collections.shuffle(*)[02:06:28] <javabot> kaineo: http://is.gd/kTYY [java.util.Collections.shuffle(List)]; http://is.gd/kTYZ [java.util.Collections.shuffle(List,Random)][02:06:29] <cheeser> ~next[02:06:29] <javabot> Another satisfied customer. Next![02:06:43] <christo_m> Theres a problem here, how can i convert a Vector object to a float array[02:06:52] <christo_m> i kno theres toArray but i dont kno what kind of array this is[02:06:53] <cheeser> ~javadoc Vector[02:06:53] <javabot> cheeser: http://is.gd/kTZa [java.util.Vector][02:07:26] <kaineo> cheeser: not importing anything, im trying to get the algorthmn by dividing list into 2, and then grab a random card from each pile and putting it in a new deck[02:07:55] <cheeser> uh. what?[02:08:20] <kaineo> im trying to get the deck to shuffle without only importing java.util.random[02:08:26] <r0bby> kaineo: this is implemented already for you...[02:09:07] <_W_> heh kaineo, why not ask your questions in the channel using only consonants as well?[02:09:15] <r0bby> import java.util.Collections;[02:09:21] <r0bby> ^^ ALL you need.[02:09:29] <gjvc> r0bby, werd[02:09:39] <r0bby> if you bothered to read the link you'd know this[02:09:50] <kaineo> r0bby: the point is, that im trying to do it without importing anything besides java.util.Random;[02:09:58] <AMcBain> r0bby: <devil's-advocate>but *it* might import Random[02:09:58] <r0bby> then Collections.shuffle(myList);[02:10:07] *** r0bby was kicked by cheeser (pay attention)[02:10:10] *** r0bby has joined ##java[02:10:37] *** initialzero has joined ##java[02:10:38] <christo_m> cheeser: can i do v.toArray(float)[02:10:44] <cheeser> ~tias[02:10:44] <javabot> Try it and see. You learn much more by experimentation than by asking without having even tried.[02:10:47] <christo_m> how can i make it a certain data type the docs arent clear[02:11:25] <r0bby> ~javadoc Vector[02:11:26] <javabot> r0bby: http://is.gd/kTZa [java.util.Vector][02:11:35] <christo_m> well i tried and it didnt work, so now i wasted time, and its still broken[02:11:47] <christo_m> when one of you could just help me instead of referring me to the API which i read[02:12:07] <pstickne> well, what's broken?[02:12:10] <r0bby> Float[] f = v.toArray(new Float[v.size()]);[02:12:29] <pstickne> broooooooken![02:12:46] <_W_> christo_m, you found the answer to your question - how was that wasted time?[02:13:06] <pstickne> _W_: you waste his time :( it would have just "been faster" to tell him...[02:13:09] <r0bby> christo_m: you waste our time by not reading[02:13:20] <kaineo> anyone see what's wrong with this code? http://eugeneciurana.com/pastebin/pastebin.php?show=40690, it's meant to removeElementAt countloop[02:13:24] * pstickne is so bored of class[02:13:33] <christo_m> Compatibility errers r0bby[02:13:43] <pstickne> typing errors, christo_m[02:13:47] <christo_m> not quite[02:13:50] <christo_m> direct copy and paste[02:14:07] <pstickne> errers is likely not the word you wished to employ[02:14:17] *** bitcrave has joined ##java[02:14:28] *** aTypical has joined ##java[02:14:33] <jottinger> re[02:14:40] <pstickne> gexp![02:14:41] <christo_m> sorry, english isnt my first language, but feel free to remain an elitist[02:14:43] <r0bby> christo_m: pass in an array[02:14:49] <pstickne> christo_m: a proletist :-)[02:14:51] <jottinger> christo_m: thank you![02:14:56] <christo_m> r0bby: pardon?[02:14:56] <r0bby> of the type stored in the List[02:15:05] <jottinger> I wanted someone's permission to be an elitist[02:15:06] <r0bby> That's what T[] is[02:15:07] <christo_m> r0bby: i tried what you posted above[02:15:14] <_W_> kaineo, you know that there already exists implementations of linked lists in Java, right?[02:15:22] <pstickne> (but it kinda sucks)[02:15:23] <_W_> java.util.LinkedList (!) is one[02:15:34] <kaineo> _w_ like i was saying, i only want to import java.util.Random;[02:15:37] <kaineo> nothing else[02:15:41] <_W_> not my problem[02:15:44] <pstickne> (j.u.LL just has a List /implemented/ as a LL, it doesn't really behave like a nice cons list :-/)[02:16:05] <_W_> I don't see why /anyone/ would help you do something so retarded, to be honest[02:16:17] <initialzero> pstickne: what is a cons list[02:16:49] <pstickne> initialzero: a list compromised of cells, where each cell has a 'data' and a 'next' (car/cdr in lisp talk)[02:17:00] <pstickne> initialzero: e.g. the most basic type of single-linked list[02:17:14] <pstickne> initialzero: the cells are called 'cons' cells in lisp, hence a cons list[02:17:21] <initialzero> pstickne: ahh, didn't get the java ref. I had to take scheme. I recall[02:17:23] *** svm_invictvs has quit IRC[02:17:32] <pstickne> initialzero: yay :)[02:17:35] <pfn> so why is a cons list so great?[02:17:35] <_W_> that's worth caring about?[02:17:42] *** dk_schrute has joined ##java[02:17:48] *** dk_schrute has quit IRC[02:17:55] *** progre55 has joined ##java[02:18:06] <initialzero> pfn: it's only great if you like the grateful dead[02:18:15] <pstickne> pfn: if a language allows functional-type modeling of cons lists they can be used be used nicely -- one very important thing is cons lists are /IMMUTABLE/[02:18:24] <r0bby> christo_m: this should work[02:18:26] <r0bby> Float[] f = v.toArray(new Float[v.size()]);[02:18:35] *** dk_schrute has joined ##java[02:18:36] <pfn> oh no, more fp idealization coming up[02:18:38] * pfn wnaders off[02:18:42] <pstickne> pfn: opposed to j.u.LL, which you can modify, but performing operations is mutative and destructive[02:19:00] <pstickne> pfn: it's just a handy construct :)[02:19:06] <_W_> you know why? because most people need a list they can modify[02:19:13] <christo_m> ok but it doesnt[02:19:17] <christo_m> i pmed you with the errors[02:19:18] <jottinger> _W_: no they don't[02:19:30] <christo_m> r0bby: its expecting a Float but it gets an Object it says[02:19:39] *** dk_schrute has quit IRC[02:19:41] <initialzero> christo_m: cast it[02:19:53] <_W_> jottinger, well, I've not seen any use of LinkedList where it wasn't mutated[02:20:06] <pstickne> _W_: because it can't be the other way :)[02:20:12] <r0bby> Float[] f = (Float[])v.toArray(new Float[v.size()]);[02:20:31] <pstickne> (as per j.u.LL implementation)[02:20:52] <initialzero> christo_m: or better just use the reference passed into toArray[02:21:05] <pfn> pstickne, Collections.unmodifiable... or Arrays.asList good enough...[02:21:11] <pstickne> _W_: not that I'm particular arguing for a cons-list in Java (with Java syntax), but I think they have a very good place[02:21:15] <pstickne> pfn: it's not the same[02:21:18] <r0bby> there is a type for maps and sets too![02:22:25] <_W_> pstickne, I like arrays[02:22:33] <pstickne> pfn: it's not that they are not mutative, it is the fact that new lists can be created from existing ones easily through decomposition and joining[02:22:39] <_W_> (and array-backed data structures like ArrayList)[02:23:01] <pstickne> pfn: while leaving the original lists intact[02:23:13] <_W_> you have CopyOnWriteArrayList[02:23:32] <pstickne> _W_: yeah, but different characteristics (iirc)[02:23:48] <pstickne> _W_: anyway, off topic I guess (I'm not argue for cons-lists /in/ Java mind you :-)[02:24:07] *** dk_schrute has joined ##java[02:24:13] <initialzero> pstickne: what about using variable argument lists? isn't that a bit like an immutable list?[02:24:20] *** asap18 has joined ##java[02:24:24] <dk_schrute> horra[02:24:27] *** dk_schrute is now known as svm_invictvs[02:24:30] <svm_invictvs> Werid[02:24:42] <pstickne> initialzero: no. that is just magic to convert a variable number of arguments to an array upon method invocation[02:25:23] <christo_m> gramschmidt.java:12: gs(float[]) in gramschmidt cannot be applied to (java.lang.Float[])[02:25:27] <christo_m> what the hell is going on[02:25:34] <_W_> pstickne, functional programming is useful and good - when taken in moderation. Purism rarely helps[02:25:51] <pstickne> _W_: hey, don't look at me for purism -- I use Scala, not Haskell ;-)[02:25:58] <dmlloyd> float[] and Float[] are not the same thing, christo_m[02:26:17] *** svm_invictvs has quit IRC[02:26:20] <christo_m> really?[02:26:23] <christo_m> what the hell[02:26:30] <dmlloyd> ~~ christo_m primitives[02:26:30] <javabot> primitives are 8 of the 9 non-Object types in Java (the special type "void" being the ninth): byte, short, int, long, float, double, boolean, and char. See http://java.sun.com/docs/books/tutorial/java/nutsandbolts/datatypes.html for more information.[02:26:38] <dmlloyd> ~~ christo_m javadoc Float[02:26:42] *** dk_schrute has joined ##java[02:26:42] <javabot> christo_m, too many results found. Please see your private messages for results[02:26:46] <dmlloyd> heh[02:26:49] <dmlloyd> that's not good[02:27:07] <dmlloyd> haha, holy crap[02:27:16] <dmlloyd> that is a LOT of Floats[02:27:22] <dmlloyd> who knew[02:27:22] *** amnesiac has quit IRC[02:27:25] *** pandora-- has quit IRC[02:27:26] *** dk_schrute has left ##java[02:27:28] *** dk_schrute has joined ##java[02:27:34] *** hrehf has quit IRC[02:27:36] *** dk_schrute is now known as svm_invictvs[02:27:38] <svm_invictvs> ><[02:27:46] <svm_invictvs> Sorry for all the connects/disconnects[02:27:59] <dmlloyd> time to open a javabot bug...[02:28:09] <svm_invictvs> What's up w/ Javabot?[02:28:09] *** amnesiac has joined ##java[02:28:10] *** nvictor has joined ##java[02:28:10] <pstickne> don't worry, we just called you a n00b each time you dc'ed[02:28:14] <initialzero> christo_m: Float[] f = new Float[v.size()]; v.toArray(f);[02:28:19] <dmlloyd> svm_invictvs: ask for javadoc for Float :)[02:28:27] <initialzero> christo_m: just use the reference[02:28:44] *** nvictor has left ##java[02:29:10] <christo_m> initialzero: how can i initilize a Float then?[02:29:16] <christo_m> i cant do like Float sum = 0.0; can i[02:29:21] <svm_invictvs> ~javadoc Float[02:29:22] <javabot> svm_invictvs, too many results found. Please see your private messages for results[02:29:29] <_W_> christo_m, try it and see[02:29:39] <initialzero> christo_m: Float sum = new Float(0,0);[02:29:40] <christo_m> i did[02:29:43] <christo_m> i get double error[02:29:51] <svm_invictvs> dmlloyd: hm?[02:29:54] <pstickne> (is a double a float?)[02:30:03] <initialzero> christo_m: or use v.add(1f)[02:30:13] <dmlloyd> pstickne: a double is like a float, only bigger - more precision[02:30:14] <svm_invictvs> No.[02:30:25] <pstickne> float x = 0.0; // :-)[02:30:34] <dmlloyd> svm_invictvs: most of those results are useless.[02:30:38] <dmlloyd> svm_invictvs: http://kenai.com/jira/browse/JAVABOT-28[02:30:39] <svm_invictvs> dmlloyd: I see.[02:30:41] <kaineo> so no one can help me with the removeAt method?[02:30:43] <pstickne> (actually, that might work? although other values should barf...)[02:31:04] *** Vicfred has joined ##java[02:31:19] <initialzero> christo_m: http://pastebin.ca/1347373[02:31:27] *** AlanasAnikonis has quit IRC[02:31:58] *** Daniel_H has quit IRC[02:32:57] <_W_> kaineo, you might have to face that the ones who can, won't[02:33:38] <svm_invictvs> ugh, I wish I could return multiple results.[02:33:41] <svm_invictvs> in java[02:33:49] <initialzero> svm_invictvs: why?[02:33:49] <svm_invictvs> w/o having to return some type of object[02:33:57] *** Razec has quit IRC[02:34:00] <svm_invictvs> initialzero: because I want to return 4 points making up a rectangle.[02:34:10] <initialzero> svm_invictvs: but not a rectangle?[02:34:23] <svm_invictvs> I dont' wanna allocate a new object for the return, yes[02:34:42] <initialzero> svm_invictvs: you need to think more object oriented imo[02:34:49] <svm_invictvs> initialzero: no, I don't.[02:34:52] <initialzero> svm_invictvs: there is nothing wrong with using new[02:35:01] <svm_invictvs> initialzero: Normally I'd agree with you.[02:35:09] <svm_invictvs> initialzero: but not right now.[02:35:20] <_W_> oh, no, a new object![02:35:22] <svm_invictvs> J2ME[02:35:24] *** Bonix has quit IRC[02:35:24] <initialzero> svm_invictvs: then use the parameter list[02:35:32] <svm_invictvs> initialzero: J2me[02:35:36] <svm_invictvs> not supported[02:35:39] *** christo_m has quit IRC[02:35:40] <initialzero> svm_invictvs: ew[02:35:41] <_W_> heh, are mobile VMs really that bad?[02:35:47] <svm_invictvs> _W_: yes, they are[02:36:06] <initialzero> more like J2!ME[02:36:08] <_W_> I was reading an article the other day about what to avoid when coding for android (don't dereference fields more than once! and similar)[02:36:22] <svm_invictvs> _W_: Yeah.[02:36:36] <svm_invictvs> Unfortunately, Embedded and OOP don't always work well together.[02:36:47] <_W_> I don't see why it couldn't[02:36:55] <_W_> just not enough effort being expended on it, I guess[02:37:50] <initialzero> svm_invictvs: why not use an array as your return, if you're gonna get ugly, get ugly[02:37:58] <svm_invictvs> Well, to make it return a rectangle class...I have to create the rectangle class which is a 200 byte penalty in the jar file, in addition I have to allocate it when I use it (Rather than just store it on the stack) then worry about the fact that the more I use new the more I fragment my very very small precious 2mb of heap.[02:38:24] <svm_invictvs> When I wish I could just pass the four ints in by reference[02:38:43] <initialzero> svm_invictvs: yeah, that's second best to a rectangle[02:38:56] <svm_invictvs> I guess I could return an array.[02:39:01] <svm_invictvs> That's not so bad[02:39:12] <svm_invictvs> Oh and the class loader doesn't unload classes on Mobile VMs[02:39:12] <initialzero> svm_invictvs: {x,y,width,height}[02:39:18] <svm_invictvs> so every fucking class you instantiate...[02:39:32] <svm_invictvs> yep, that's more heap you burn just to laod the fucking class into memory.[02:39:47] <pfn> #1 answer if you ever need to return "tuples" in java is to use an array[02:39:53] <initialzero> svm_invictvs: damn are you sitting in a pile of broken glass too? that's hardcore[02:39:55] <pfn> if you need a "pointer" use single-element arrays as input[02:40:17] <dmlloyd> maintain your own heap of rectangles :)[02:40:23] <dmlloyd> one big array[02:40:27] <pfn> e.g. int[1] x ...; foo(x, ...) { x[0] = ... }[02:40:27] <initialzero> pfn: svm_invictvs may as well return an array[02:40:32] <svm_invictvs> dmlloyd: I actually am stacking them in an array.[02:40:33] <TryNiX> How can I round to 7 if value is 6.1?[02:40:37] <whaley> or just write another class... since the multiple things you want to return probably have some relationship with each other that needs to be encapsulated[02:40:39] <pfn> TryNiX, ceil[02:40:42] <dmlloyd> pass and return an index into that big array, which becomes your 'pointer'[02:40:44] <TryNiX> cheers[02:40:58] <initialzero> TryNiX: round up[02:40:58] <svm_invictvs> dmlloyd: I'm parsing them from a properties file athat I read on the fly[02:41:01] <whaley> but that's too oop, so nm... I forgot we all love tuples and fp now[02:41:02] *** rdancer has joined ##java[02:41:12] *** magcius has joined ##java[02:41:27] <svm_invictvs> copy/paste coding is easiest actually ><[02:41:53] <initialzero> whaley: not me[02:42:13] *** magcius has quit IRC[02:43:09] *** radixor_ has joined ##java[02:44:56] *** ahughes has quit IRC[02:45:10] *** ahughes has joined ##java[02:45:38] *** Scaryteam has joined ##java[02:46:57] *** magcius has joined ##java[02:47:00] *** radixor has quit IRC[02:47:26] *** aTypical has quit IRC[02:47:55] *** magcius has quit IRC[02:48:17] *** trustin has quit IRC[02:48:21] *** pstickne has quit IRC[02:48:34] *** magcius has joined ##java[02:49:32] *** magcius has quit IRC[02:50:10] *** magcius has joined ##java[02:50:20] *** radixor has joined ##java[02:51:04] *** amnesiac has quit IRC[02:51:06] *** magcius has quit IRC[02:51:44] *** magcius has joined ##java[02:52:36] *** magcius has quit IRC[02:52:50] *** Varox has joined ##java[02:53:15] *** magcius has joined ##java[02:53:53] *** raphaf has joined ##java[02:54:05] *** lilako has joined ##java[02:54:05] *** magcius has quit IRC[02:54:31] *** cmccormick has joined ##java[02:54:43] *** magcius has joined ##java[02:55:25] *** magcius has quit IRC[02:57:33] *** eidolon has quit IRC[02:58:36] *** jeremy_c has quit IRC[02:58:37] *** Scaryteam has quit IRC[02:59:01] *** cactaur has joined ##java[02:59:56] *** TryNiX has quit IRC[03:00:17] *** christo_m has joined ##java[03:01:22] *** bas-i has quit IRC[03:01:47] <svm_invictvs> hm[03:01:50] *** Varox has quit IRC[03:03:27] *** dublisk has joined ##java[03:04:18] *** Ven]n has quit IRC[03:06:11] *** radixor_ has quit IRC[03:11:23] *** doc`` has quit IRC[03:13:07] *** Level1 has quit IRC[03:14:28] *** ttmrichter has quit IRC[03:14:34] *** morkar-- has joined ##java[03:15:47] *** AskHL has quit IRC[03:19:28] <christo_m> svm_invictvs: you there? http://pastebin.com/m50413626[03:20:20] <svm_invictvs> looks okay?[03:20:27] <svm_invictvs> You may have to use...[03:20:33] <svm_invictvs> Pattern.quote("(");[03:20:34] *** aleksei has quit IRC[03:20:37] <christo_m> svm_invictvs: i get some Object crap error tho[03:20:46] <svm_invictvs> Hm?[03:20:54] *** pstickne has joined ##java[03:21:04] <christo_m> svm_invictvs: where i put the comment, it seems that the compiler doesnt see that theyre vectors inside vectors[03:21:12] <christo_m> im trying to make sure that all their lengths are equal[03:21:15] <svm_invictvs> Also, dont' use vectors[03:21:17] <svm_invictvs> use ArrayList[03:21:23] <christo_m> its too late[03:21:54] *** AskHL has joined ##java[03:22:13] <AMcBain> "too late" -> "too lazy to change" (?)[03:22:26] <christo_m> no, assignment is due[03:22:34] <christo_m> i dont have time to make changes like that[03:22:55] <pstickne> it's a trivial change[03:23:25] *** zeno___ has joined ##java[03:23:35] <zeno___> what version of java is closest to suns for ARMv6-compatible processor rev 2 (v6l)?[03:24:02] <svm_invictvs> zeno___: What's this?[03:24:12] <pstickne> (a JBC-enabled processor?)[03:24:20] <zeno___> svm_invictvs: tmobile g-1[03:24:29] <pstickne> zeno___: uhh...[03:24:46] <christo_m> svm_invictvs: any idea what happened there tho[03:25:02] <zeno___> pstickne: icedtea? gcj? or something else[03:25:06] <christo_m> http://pastebin.com/m50413626 lines 20-23[03:25:07] <pstickne> zeno___: google?[03:25:12] <christo_m> for anyone who wants to see[03:25:59] <zeno___> pstickne: not too many people installing jvaa on it so nothing[03:26:13] <pstickne> zeno___: I thought the G-1 was Java-by-default[03:26:32] *** sepult has quit IRC[03:26:42] <zeno___> pstickne: well im wanting to run a normal java app, (via the debian install on it)[03:27:07] <pstickne> http://en.wikipedia.org/wiki/Google_Android[03:27:40] <zeno___> pstickne: right its a swing app though[03:28:00] <pstickne> dunno :)[03:28:12] <christo_m> ahh i see my error, i was using generics[03:28:27] <christo_m> instead of specifying types like List<String> l = new ArrayList<String>();[03:29:37] *** mosno has quit IRC[03:30:33] <pstickne> uhh[03:30:47] <pstickne> I don't see how...[03:30:51] <pstickne> oh, nevermind[03:30:58] <zeno___> has anyone tried to add type interface using generics to java?[03:31:04] *** ttmrichter has joined ##java[03:31:21] <dmlloyd> type interface? what do you mean by that[03:31:25] * zeno___ looks to see if scala has them[03:31:41] <reverend> type inference, by chance?[03:31:42] <zeno___> dmlloyd: where you dont declare the type, but the complier inferrs it from the context[03:31:50] <dmlloyd> oh, type /inference/[03:31:57] <zeno___> yeah sry :)[03:31:59] <dmlloyd> java doesn't do a great job at it[03:32:20] *** morkar- has quit IRC[03:32:50] *** giaco has quit IRC[03:32:53] <reverend> i'm just fine without type inference[03:32:58] <reverend> never use it in C# either[03:34:04] *** trustin has joined ##java[03:34:40] <zeno___> reverend: yeah i just think the java generics syntax is painful, was thinking of possible fixes[03:34:59] *** FireSlash has quit IRC[03:35:12] *** initialzero has quit IRC[03:36:15] *** Goat25 has joined ##java[03:36:59] <jottinger> zeno___: "use a language that supports generics better" <-- pretty much the best option[03:37:04] <jottinger> or use duck typing languages[03:37:08] *** ionine_ has joined ##java[03:37:08] *** ChanServ sets mode: +b *!*n=ionine@*.dyn.optonline.net[03:37:08] *** ionine_ was kicked by ChanServ (Banned: seriously. just stfu.)[03:37:22] <dmlloyd> and yet, he always returns[03:37:32] <jottinger> ;)[03:37:45] <Nebulam> type inference is terrible, just look at lambda expressions in c#. That is the worst thing that could happen to that language.[03:37:53] *** monestri has joined ##java[03:38:39] <dmlloyd> there are certain things that java could do better, like infer type variables across multiple method calls (the "Map<Thing1, Thing2> map = synchronized(hashMap());" problem)[03:38:49] <dmlloyd> synchronizedMap( I meant[03:38:58] <cheeser> that would be nice.[03:39:32] <dmlloyd> I end up with composition methods like synchronizedHashMap etc[03:39:39] <cheeser> ick[03:39:44] <dmlloyd> yeah, annoying[03:45:56] *** josemoreira has quit IRC[03:46:37] *** ScottG489 has quit IRC[03:50:28] *** HeatHawk[AP2] has quit IRC[03:50:43] *** bhz- has joined ##java[03:53:46] <christo_m> http://pastebin.com/m507d110b somethings wrong with my GS algo apparently[03:54:05] *** HeatHawk[AP2] has joined ##java[03:54:15] <christo_m> Im getting a Null pointer exception at line 73[03:55:33] *** ScottG489 has joined ##java[03:55:37] <reverend> then you're derferencing something that's null.[03:56:51] <Goat25> christo_m: based on a quick glance...Float[][] a is an array of arrays. You have to allocate each row separately[03:57:43] *** azanar has quit IRC[03:59:03] <waz> ty[04:00:45] <christo_m> Goat25: dont lie to me[04:00:48] <christo_m> god dammittt[04:01:01] <wolfe> ^_^[04:01:05] <wolfe> holy monkey shit[04:01:08] <christo_m> Goat25: whats the syntax before my head explodes[04:01:13] <christo_m> when i close my eyes i see java code[04:01:21] <christo_m> no rhyming intended[04:01:23] *** whaley has quit IRC[04:01:25] <wolfe> hibernate 2 java tool converted the database to a java class...[04:01:39] *** flippo has joined ##java[04:01:43] <wolfe> 313 parameters, no wonder java throws a too many parameters error[04:02:12] <wolfe> can we say bad database design? >.>[04:02:46] <wolfe> that was just ONE table >:/[04:02:46] <dmlloyd> hahaha[04:02:51] <dmlloyd> 313 parameters[04:02:52] * wolfe facepaws[04:03:14] <wolfe> this... coming from a guy who tells me, "I've been developing database applications for 15 years"[04:03:18] <Goat25> christo_m: nm, i think "a" is allocated ok[04:03:24] <dmlloyd> I could see having 313 columns on a table, if it's a very special case[04:03:41] <_W_> I couldn't[04:03:41] <dmlloyd> but there's no way you'll ever convince me that it ought to be converted to a series of method parameters[04:03:48] <wolfe> dmlloyd: I'm looking at it, they could be seperated in to different tables and referenced from the main table[04:04:02] <wolfe> it's like he put almost damn everything in to this one table[04:04:11] * wolfe frowns[04:04:13] <dmlloyd> ask your 15-years database friend if he knows what "normalization" is[04:04:19] <christo_m> Goat25: so whats wrong exactly, my partner wrote the algo so ill have to check in with him, but he gave me his pre conditions and i thought they were satisfied[04:04:22] <flippo> This is a learning opportunity.[04:04:37] <wolfe> dmlloyd: he is a monkey and a certie, I don't expect him to know much of anything[04:05:05] <wolfe> I was going to use WaveMaker, but I'm forced to use Python because django converts the database in to classes for me[04:05:07] <dmlloyd> then tell him that until he can explain the normal forms to you, he should shut his filthy gob and go back to kicking off backup jobs[04:05:20] <wolfe> thankfully python has no limits, but this completely ruined my really quick app design[04:05:21] <dmlloyd> don't be a doormat[04:05:42] <wolfe> dmlloyd: unfortunately data is populated and there is.. *cough* an access app made[04:05:51] <wolfe> so I can't change anything without updating his horrid code[04:05:58] <dmlloyd> sounds like a replacement job then[04:06:02] <dmlloyd> better get to it[04:06:03] <flippo> (Once you make a programming decision you should stick with it, until the compiler disagrees or until you receive early retirement.)[04:06:06] <wolfe> an access app which uses ODBC, :|[04:06:19] <wolfe> dmlloyd: trying right now.. behind his back, in to a nice web app using dojo[04:06:23] <wolfe> I'm going to design a nice RIA[04:06:28] <wolfe> then rub it in his face :)[04:07:19] <christo_m> Goat25: you still there??[04:07:37] * wolfe shrugs, this one table is going to give me nightmares[04:08:20] *** felipe_ has quit IRC[04:08:49] <reverend> wolfe: are you fucking kidding me, 300+ columns in one table?[04:09:14] <AMcBain> holy shit. that's not even manageable![04:09:45] <reverend> i'd probably take it upon myself to cleanse the gene pool by elinating that person[04:10:38] <reverend> i really need a new laptop keyboard[04:11:43] *** progre55 has quit IRC[04:11:52] <reverend> MANAGEABLE[04:12:03] *** popcornPanic has quit IRC[04:12:17] *** juacom99 has joined ##java[04:12:35] <r0bby> wolfe: you need to clean up that data model[04:12:58] <juacom99> could anyone plese help me? i need to convert drom byte[] to uint in java[04:13:05] *** Woflborg has quit IRC[04:13:13] <juacom99> *from[04:13:22] <_W_> there's no "uint" in java[04:13:38] <juacom99> :S[04:13:42] <_W_> and bytes can encode integers in a number of ways[04:13:50] <pstickne> nooo![04:14:02] <pstickne> there is actually an unsigned integer type ... :)[04:14:06] <juacom99> i'm resiving a packaje length fom a server[04:14:10] <juacom99> and time to time[04:14:18] <juacom99> the length is negative S[04:14:25] <pstickne> juacom99: bad bad![04:14:33] <reverend> guess you're ABSOLUTELY FUCKED then[04:14:34] <_W_> juacom99, then you're not decoding the bytes correctly[04:14:43] <juacom99> ojne[04:14:46] <juacom99> *one sec[04:14:48] <pstickne> juacom99: I always up-promote to the next highest-kind (e.g. long to hold 32 bits of numbers)[04:14:52] <juacom99> i'll past the function[04:15:01] <_W_> reverend: don't IRC when drunk?[04:15:09] <pstickne> _W_: :([04:15:22] <reverend> dead sober[04:15:27] <christo_m> Goat25: :([04:15:30] <reverend> just tired again[04:15:33] <christo_m> r0bby: perhapes you can help me![04:15:39] <christo_m> http://pastebin.com/m507d110b[04:15:42] *** ilaggoodly has quit IRC[04:15:45] <christo_m> getting errors at around 73[04:16:06] <juacom99> this is my parse code[04:16:08] <juacom99> http://paste.ubuntu.com/123116/[04:16:10] *** LordMetroid has quit IRC[04:16:17] *** Ephidaurus has quit IRC[04:16:20] <reverend> learning to debug is a required skill and one you should work on christo_m[04:16:36] <juacom99> pstickne: you mean if i need a int you parse it to long[04:16:41] <juacom99> and so on?[04:16:44] <HeatHawk[AP2]> in C with posix sockets, negative length == error with transfer....[04:16:53] <Goat25> christo_m: use the debugger to stop it right before the line with the exception and see which reference is null[04:17:04] <pstickne> juacom99: if I want to treat it exclusively as unsigned, normally[04:17:10] <christo_m> Goat25: im compiling on a linux machine, how do i evoke the debugger lol[04:17:19] <pstickne> juacom99: not that it's strictly required -- bits are bits -- but it makes life easier[04:17:20] <juacom99> that may worlks[04:17:30] <christo_m> Goat25: doing it by VIM + commandline btw[04:17:33] <juacom99> *works[04:17:36] *** monestri has quit IRC[04:17:41] <dmlloyd> I myself tend to just use int[04:17:44] <juacom99> HeatHawk[AP2]: i did that if[04:17:55] <Goat25> christo_m: jdb[04:17:57] <juacom99> just before i call thoes functions[04:18:05] <reverend> christo_m: debugging is a skill, not a utility[04:19:05] <juacom99> here is where i call that function[04:19:06] <juacom99> http://paste.ubuntu.com/123117/[04:19:07] *** rajesh has quit IRC[04:19:44] <christo_m> reverend: i know i was asking Goat25 something[04:20:35] <r0bby> christo_m: error?[04:21:30] <reverend> ERROR U53R: PEBCAK[04:21:37] <r0bby> christo_m: why do you need go from Lists to arrays?[04:21:45] <r0bby> just use a List and be done![04:21:57] *** trustin has quit IRC[04:22:59] <r0bby> christo_m: protip: when you ask for help on a programming channel give the code _AND_ the error[04:23:09] <r0bby> people typically dont feel like running your code[04:23:33] <reverend> he did, it's 'somewhere around line 73'[04:24:01] <r0bby> yeh[04:24:05] <r0bby> error message is what[04:24:30] <r0bby> and christo_m by the way: arrays from 0 to length-1[04:24:48] <r0bby> do <array.length is the same as doing <=array.length-1[04:25:09] <r0bby> s/do/doing/[04:25:13] <r0bby> that's blaring thing #1[04:25:54] <r0bby> warning: my attenton span blows i lose interest after 2 minutes[04:26:31] <cheeser> and that's a victory for all mankind[04:27:35] <r0bby> yeh:)[04:27:39] <r0bby> suppose.[04:27:53] * r0bby cries[04:27:54] *** tomvolek has joined ##java[04:29:32] <r0bby> christo_m: also: while((String line = reader.readLine()) != null) { /* process each line */ }[04:30:03] *** juacom99 has quit IRC[04:30:25] *** juacom99 has joined ##java[04:30:29] *** woonix has joined ##java[04:31:09] *** raphaf has quit IRC[04:31:47] *** taxon has quit IRC[04:32:12] *** taxon has joined ##java[04:33:14] *** waz has quit IRC[04:34:01] <[[thufir]]> how do you know whether jakarta dbcp is implemented? I *think* I'm using it: http://pastebin.com/m76d84a69 is that code reasonable for connection pooling?[04:34:57] *** BW^- has joined ##java[04:35:03] <BW^-> hi! any idea why i get this error?: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class 'org.gjt.mm.mysql.Driver'[04:35:11] <BW^-> because, doing Class.forName(mysqlDrvClass).newInstance(); right previous to that on the same class gives no error[04:35:40] <BW^-> it's so strange because loading the mysql driver worked well just until i tried to use the DBCP yesterday.[04:36:02] <[[thufir]]> BW^-: you're using dbcp too? :)[04:37:04] *** Goat25 has quit IRC[04:37:15] <BW^-> [[thufir]]: how do you mean?[04:37:29] <BW^-> i have no option, i must, because i do LOCK:s in my multithreaded app[04:37:29] *** woonix has left ##java[04:37:42] <BW^-> i realized yesterday LOCK:s are connection-global[04:37:47] <BW^-> soo, how do i get it working?[04:38:01] <[[thufir]]> BW^-: I mean that when I look up which settings to use I get contradictory answers[04:38:49] <BW^-> aha?[04:39:08] <BW^-> i find almost no answer at all. :-}[04:39:25] <[[thufir]]> BW^-: http://mail-archives.apache.org/mod_mbox/tomcat-users/200807.mbox/%3Cc09049bf0807052339u6e114980h14a053c4a7c82c9d at mail dot gmail.com%3E[04:40:52] <BW^-> "hidden bears, etc."[04:40:54] <BW^-> :)[04:41:00] *** isr` has quit IRC[04:41:33] <tomvolek> hi guys, a begginers question :) what is a good example of a deadlock() ?[04:41:47] <cheeser> ~~ tomvolek google thread deadlock[04:41:47] <javabot> http://letmegooglethatforyou.com/?q=thread+deadlock[04:42:02] <BW^-> [[thufir]]: which is your CATALINA_HOME?[04:42:31] <BW^-> ah, on my machine /usr/share/tomcat5.5 , huh[04:43:24] *** azanar has joined ##java[04:43:24] <[[thufir]]> BW^-: yeah, similar (tcat6)[04:46:49] *** tomvolek has quit IRC[04:47:03] *** doc`` has joined ##java[04:49:14] <BW^-> ah, fixed. for me it was i needed to copy mysql driver to CATALINA_HOME/common/lib .[04:49:17] *** felipe_ has joined ##java[04:50:45] *** christo_m has quit IRC[04:56:42] *** FMJaguar has quit IRC[04:57:15] *** kater has joined ##java[05:00:57] <r0bby> ugh i wish i could shut this god damn thing up IDEA is giving w ClassNotFoundException when it _DOES_ exist![05:01:35] <cheeser> ah, newbies arguing with the computer. it's so cute to watch.[05:02:14] *** phyburn has joined ##java[05:03:22] <reverend> the eternal newbie[05:06:11] <aceofspades19> r0bby: thats why I hate using IDEs like IDEA ;)[05:06:45] <AMcBain> come on, r0bby's not all that bad, just despicable some of the time ...[05:07:06] <wolfe> reverend, r0bby: no kidding :/[05:07:19] <wolfe> it just amazes me what some people come up with in designs[05:07:49] <AMcBain> what about 'cat'? that's a nice editor.[05:07:58] <AMcBain> well, technically a command, but ...[05:08:00] *** zed_DX has joined ##java[05:08:06] <reverend> /bin/ed[05:08:10] <reverend> all y'all need[05:08:25] <wolfe> he is going to be upset with me because HE was supposed to write the web interface, I bet he doesn't even know the table design, cause you know he didn't document ANYTHING[05:08:35] <AMcBain> I figured out how to change lines ... but that's all I can do with Ed.[05:08:56] <reverend> i'd substitute 'design' with 'layout' in that sentence[05:09:03] <reverend> but i'm a bit of a pedant[05:09:15] <wolfe> ^_^[05:09:33] <AMcBain> If you give me vi, I can do some real damage ... and not in the good sense :P[05:10:00] <reverend> ed is just vi with a head injury[05:10:09] <AMcBain> hehehe[05:10:41] <AMcBain> When I'm on Linux I don't mind nano, actually, assuming it was compiled with a default of line-wrap: off ...[05:10:52] <reverend> nano just reminds me of pico[05:10:56] <reverend> which irritates me[05:10:56] <AMcBain> (which my scholl *didn't* do)[05:11:06] <AMcBain> It's supposed to be like it[05:11:15] <reverend> spent several years reading email in pico[05:11:17] <reverend> and hated it[05:11:36] <AMcBain> to each his own[05:12:34] <AMcBain> ooo, nano finally got undo support![05:12:41] <AMcBain> (not that I ever needed it :P)[05:13:16] *** kater_ has quit IRC[05:13:47] *** gizmola has joined ##java[05:18:00] *** Kwitschibo has quit IRC[05:18:34] *** gizmola has quit IRC[05:19:24] *** gizmola has joined ##java[05:21:43] *** morkar- has joined ##java[05:23:03] *** morkar- has quit IRC[05:23:12] *** morkar- has joined ##java[05:23:38] *** Csow has joined ##java[05:24:14] *** boringwall has quit IRC[05:24:55] *** boringwall has joined ##java[05:27:24] *** caverdude has joined ##java[05:28:11] * caverdude is using tomcat again[05:28:41] <caverdude> I'm trying to setup my laptop so that I can edit the web sites locally, test them with tomcat, then make the war file and upload[05:28:58] <caverdude> new experiance for me really, i was editing the web sites live last time[05:29:19] *** rainmann has joined ##java[05:33:11] *** amnesiac has joined ##java[05:33:38] *** jkriesten has joined ##java[05:35:52] *** morkar-- has quit IRC[05:37:58] <[[thufir]]> do you have to create extra tables to store metadata when using jakarta odj?[05:39:06] <pstickne> caverdude: sounds like a MuchBetterApproach(TM)[05:41:44] *** delskorch has quit IRC[05:44:03] *** npm has quit IRC[05:46:17] *** asap18 has quit IRC[05:47:14] *** ilaggoodly has joined ##java[05:47:34] *** zed_DX has quit IRC[05:48:23] <r0bby> caverdude: you can use an ant task to deploy[05:48:47] <caverdude> pstickne, well I was trying to figure out how to setup eclipse to edit two different web sites using tomcat locally outside of a jar.. but I think I'll just make two different installs of tomcat one for each web site for now[05:49:00] <caverdude> r0bby cool, I plan on doing that sooner or later[05:49:45] <pstickne> caverdude: maven probably can handle this well... I only use what other people create though :)[05:51:40] <caverdude> I may be able to forgo the use of war files for now though[05:51:46] <caverdude> until I learn a bit more[05:51:52] *** juacom99 has quit IRC[05:52:43] *** epoxy has joined ##java[05:52:54] *** flippo has quit IRC[05:55:12] <Csow> ~pastebin[05:55:12] <javabot> http://www.papernapkin.org/pastebin Paste the final url after you've pasted your stuff there.[05:59:00] *** lresende has quit IRC[06:01:45] *** Odin79 has quit IRC[06:02:24] <Csow> i need help and ideas writing test drivers for this method basically it is an assignment just the method signature was given and left for us to implement[06:02:27] <Csow> http://www.papernapkin.org/pastebin/view/4666/[06:03:47] *** nmbr has joined ##java[06:04:01] <nmbr> hi![06:04:30] <nmbr> quick question: i've got a dynamicly sized list, with each object in the list being an instance of a class[06:04:49] <nmbr> these instances are short lived, between 0 and 100s active at once[06:05:17] <nmbr> i do not need to maintain any sort of index locations[06:05:21] *** gnufied has quit IRC[06:05:27] <nmbr> what is the cleanest way to remove these objects from the list?[06:05:46] <dmlloyd> list.clear()[06:05:50] <dmlloyd> removed![06:06:38] <nmbr> will list.clear(i) remove that particular index?[06:06:46] <dmlloyd> no, list.remove() will[06:06:49] <dmlloyd> ~~ nmbr javadoc List[06:06:54] <dmlloyd> the docs are there for a reason[06:06:56] <javabot> nmbr: http://is.gd/j5sr [java.util.List]; http://is.gd/j5sq [java.awt.List][06:07:02] <dmlloyd> (first one only)[06:07:16] <nmbr> list.remove() says it wont work[06:07:22] <nmbr> for this particular class[06:07:35] <dmlloyd> what do you want the remove to do exactly?[06:07:38] <dmlloyd> move all the other members up?[06:07:48] <nmbr> yea[06:07:55] <dmlloyd> ~~ nmbr javadoc List.remove(int)[06:07:55] <javabot> nmbr: http://is.gd/kVeD [java.util.List.remove(int)]; http://is.gd/kVeE [java.awt.List.remove(int)][06:08:05] <dmlloyd> first one again :)[06:08:08] *** FireSlash has joined ##java[06:08:23] <dmlloyd> that's a bad usage pattern though. You might really want a Set[06:08:55] *** blankthemuffin has joined ##java[06:09:16] <nmbr> 'cannot invoke remove(int) on the arraytype move.Classname'[06:09:36] *** morkar- has quit IRC[06:09:57] *** [[thufir]] has quit IRC[06:10:04] <nmbr> im actually using processing.org, but standard java is supposed to work 100%[06:10:07] <dmlloyd> what on earth gave you *that* error[06:10:20] <dmlloyd> um, an array isn't a list[06:10:21] <dmlloyd> ...[06:10:27] <nmbr> oh crap[06:10:47] <nmbr> hahaha okay. my brain must be fried[06:10:54] *** ilaggoodly has quit IRC[06:12:02] <dmlloyd> anyway it's not Java.[06:12:17] <dmlloyd> "Java-like syntax" does not make it Java by any stretch.[06:12:23] *** [[thufir]] has joined ##java[06:12:43] <nmbr> well, i got what i needed regardless (however dumb it was)[06:12:45] <nmbr> thanks![06:13:31] *** Junior has joined ##java[06:15:57] *** bitcrave has quit IRC[06:18:14] *** [[thufir]] has quit IRC[06:18:14] *** Ragnor has quit IRC[06:18:28] *** Ragnor has joined ##java[06:18:48] *** [[thufir]] has joined ##java[06:19:22] *** im_maciek has quit IRC[06:20:36] *** FMJaguar has joined ##java[06:22:18] *** cobolfoo has quit IRC[06:25:57] *** cybereal has joined ##java[06:27:21] *** bashoh has joined ##java[06:28:37] *** amnesiac has quit IRC[06:29:00] <[[thufir]]> to use apache ojb you just need db-ojb-1.0.4.jar and the commons jar in your classpath? there are about 50 jars in the lib folder for ojb.[06:36:14] *** trustin has joined ##java[06:37:57] *** spiderbyte has quit IRC[06:38:28] *** amz has quit IRC[06:39:41] <epoxy> Hey, i'm trying to draw a BufferedImage to a Canvas... so far I can only get 1 line drawn to the Canvas when i override the paint method.. am I missing something? http://pastebin.com/m79f842c6[06:40:38] <pstickne> does anyone know where I can find a simple /pre-made/ EJB3 EAR file? it seems like these would be easily accessible for testing deployments :([06:41:11] <pstickne> just you know ... a /thought/[06:41:24] <[[thufir]]> dunno[06:41:26] <pstickne> epoxy: a few hundred lines?[06:41:57] <pstickne> epoxy: use the smart methods[06:41:58] <epoxy> :D[06:41:59] <AMcBain> epoxy: use a JPanel instead of a Canvas[06:42:23] <epoxy> ah, alrighty[06:42:34] <pstickne> oh, I see you have a wonky data-type in there as well[06:42:37] <epoxy> then override paintComponent, correct?[06:42:38] <AMcBain> yes[06:42:55] <[[thufir]]> when adding resources for ojb, http://www.onjava.com/pub/a/onjava/2003/01/08/ojb.html?page=3, does it matter which directory? put it with web.xml?[06:43:07] <pstickne> epoxy: also check your height/width settings...[06:43:22] <pstickne> AMcBain: if I snuggle with you, will you give me a small sample EAR? :([06:43:42] <AMcBain> I've never even used EJB ...[06:43:53] <pstickne> AMcBain: :p[06:44:22] <pstickne> Thankfully at least I can start with EJB3; this a "JEEEEEEEE requirement" for a silly course :-/[06:45:14] <pstickne> gah[06:45:24] <AMcBain> epoxy: you also might want to do this in your constructor: setPreferredSize(new Dimension(width, height));[06:45:26] <pstickne> I hate it when links like foo.gz redirect to a mirror selection page[06:45:33] <pstickne> dumbest idea ever[06:45:47] *** phyburn has quit IRC[06:46:06] <AMcBain> (the default layout manager on a frame's content-pane will obey preferred-sizes and if you call pack() it'll work nicely, if that's what you're trying to do)[06:46:31] * AMcBain is tired, but has two more methods to implement.[06:47:03] <AMcBain> scratch that ... 3.[06:47:51] <pstickne> ant calling maven. swell.[06:48:08] <AMcBain> haha, wow[06:48:18] <[pwgr]> wipe your arse with sandpaper[06:48:39] *** davo has joined ##java[06:49:23] *** blankthemuffin_ has joined ##java[06:49:26] <epoxy> hm .. still getting just one line (1st line) drawn with a JPanel implementation and adding setPreferredSize and/or setSize... maybe it could be my BufferedImage. hm.[06:49:38] *** cactaur has quit IRC[06:49:50] *** FireSlash has quit IRC[06:50:09] <pstickne> I really wonder where all these bajillion things maven downloads go...[06:50:26] <AMcBain> the ether[06:50:32] <pstickne> I guess...[06:50:51] <pstickne> when did dependencies become so complicated? :([06:51:25] *** im_maciek has joined ##java[06:51:40] <AMcBain> when the programs that managed them became bloated and stupid?[06:51:57] <cybereal> it's the nature of pulling in existing code[06:52:36] *** DirtyMind has joined ##java[06:52:54] <AMcBain> as if r0bby wasn't enough ...[06:54:16] <cybereal> pstickne: seriously? they go to your local repo[06:54:21] <cybereal> usually ~/.m2/repository[06:55:02] *** igors has joined ##java[06:55:43] <cybereal> if I start fresh and do mvn install for my project, when it's finally done, there's 45mb of things in that repo heh[06:55:59] <igors> hi. I'm having troubles to load MySQL driver for a simple test with JDBC. I've added the .jar file to my CLASSPATH, but it's not working.[06:56:13] <Gracenotes> :([06:57:39] <igors> this is my CLASSPATH=/Users/igorsobreira/Packages/JavaStuff/mysql-connector-java-5.1.7/mysql-connector-java-5.1.7-bin.jar[06:59:05] *** Resistance has quit IRC[06:59:32] <[[thufir]]> igors: pastebin your code? what's the error? etc.[06:59:33] <igors> JavaConfi.plist file says $HOME/Library/Java is in my DefaultClasspath, so i've added a simbolic link from there to this mysql connector file...but still without success[07:01:00] *** dublisk has quit IRC[07:01:11] <igors> [[thufir]], http://paste.uni.cc/19711[07:01:50] <igors> [[thufir]], it always goes to ClassNotFoundException catch.[07:03:26] *** Frostix has quit IRC[07:04:06] *** Resistance has joined ##java[07:06:08] *** longbeach has joined ##java[07:06:43] *** casmo has quit IRC[07:07:13] *** CrypticSquared has joined ##java[07:10:19] *** djp[mbp] has quit IRC[07:12:50] *** Junior has quit IRC[07:13:24] *** vix85 has joined ##java[07:18:09] *** Junior has joined ##java[07:20:13] *** Vicfred has quit IRC[07:25:42] *** sebr is now known as sebr_afk[07:25:53] *** spackest has joined ##java[07:27:30] *** Mortomes has quit IRC[07:28:07] *** bindaas has joined ##java[07:28:22] <spackest> just wondering if there is a way to get the request url, including a ? via java[07:28:26] *** mesmer has joined ##java[07:28:36] <spackest> tried pretty well every request. option from a jsp[07:29:49] <mesmer> hello everyone: I've read the sun documentation on the keyword "this" I'm still unclear of how it works though can someone give me a hand?[07:30:04] *** azanar has quit IRC[07:30:51] <caverdude> mesmer inside myObject this is a reference to myObject[07:31:02] <caverdude> not to be confused with MyObject[07:31:08] *** Kwitschibo has joined ##java[07:31:11] <caverdude> meaning an instance[07:31:45] *** rullie has quit IRC[07:33:38] <caverdude> public class MyObject(){ int anIntFiled; public MyObject(int anInt){ this.anIntField=anInt;} public void foo(){ System.out.println(this.anIntField);}}[07:34:41] <caverdude> in your main method { MyObject myObject = new MyObject(5); myObject.foo(); // outputs '5' to the console[07:34:56] <caverdude> mesmer?[07:35:07] <mesmer> reading what you wrote[07:35:42] <caverdude> using this. is optional, you should use it however as a point in style[07:36:04] <caverdude> or where local variables have the same name as a field[07:36:11] <[[thufir]]> igors: are you sure that you have the driver on the classpath?[07:36:16] <mesmer> http://pastebin.com/m6750ae39 how is "this" calling another constructor?[07:37:24] <caverdude> that link got me a blank box[07:37:35] <mesmer> let me do it again[07:37:46] <caverdude> http://www.rafb.net/pastebin[07:37:52] <caverdude> or paste[07:38:04] <mesmer> http://pastebin.com/m6e7a0922[07:39:01] <mesmer> this is much better link etherpad http://etherpad.com/XoShKu51TH[07:39:15] <mesmer> caverdude: please join me there[07:39:20] <caverdude> well, it is calling the constructor[07:39:49] <caverdude> this() in any no args constructor would call the noargs constuctor[07:40:21] <caverdude> oops[07:40:30] <caverdude> in any constructor with args[07:40:33] <nmbr> is 'this' similar to 'self' in python?[07:40:35] <caverdude> would call[07:40:44] <caverdude> nmbr I don't know[07:40:51] <caverdude> sounds similar[07:41:13] <nmbr> within a class, if you want to call a class function, you call self.func()[07:41:34] <caverdude> yes[07:41:35] <mesmer> caverdude: would you join me here please http://etherpad.com/XoShKu51TH[07:41:41] <caverdude> join you?[07:41:53] <nmbr> thats good to know, i was just wondering how to do that :D[07:42:01] <mesmer> yes it is etherpad we can edit text 2gether[07:43:10] *** blankthemuffin has quit IRC[07:43:21] *** blankthemuffin_ has quit IRC[07:44:15] *** euvitudo has quit IRC[07:45:16] <igors> [[thufir]], I've added the environment variable CLASSPATH with the file. But now I've copied the .jar file to "/System/Library/Java/Extensions/" and it's working[07:45:18] <igors> thanks[07:46:00] *** igors has quit IRC[07:46:03] *** Aquanox has joined ##java[07:48:38] *** nocture has joined ##java[07:48:45] *** vix85 has quit IRC[07:52:03] *** ahughes has quit IRC[07:52:27] *** bas-i has joined ##java[07:55:59] *** bas-i has quit IRC[07:58:05] *** spackest has quit IRC[08:03:32] *** DirtyMind has quit IRC[08:04:38] *** NiSoOo has quit IRC[08:06:21] *** Angel-SL has joined ##java[08:06:21] *** repnop has quit IRC[08:11:06] *** AMcBain has quit IRC[08:11:25] *** deepjoy has joined ##java[08:14:13] *** tom17bombadil has joined ##java[08:14:29] *** paulweb515_ has quit IRC[08:18:38] *** epoxy has quit IRC[08:19:20] *** Level1 has joined ##java[08:20:22] *** mesmer has quit IRC[08:28:41] *** idea4good has joined ##java[08:30:03] *** caverdude has quit IRC[08:31:20] <idea4good> I dont see the getTransaction on session object on hibernate[08:31:37] <idea4good> what could be hte reason[08:32:02] <cybereal> it isn't there or you're blind[08:32:02] *** rainmann has left ##java[08:32:55] <idea4good> it is not there i session is of type hibernate.Session[08:33:13] <idea4good> on session i c begin transaction but not getTransaction[08:33:18] <idea4good> something with eclipse?[08:33:27] <cybereal> not likely[08:33:34] *** ckebabo has joined ##java[08:34:55] *** spiderbyte has joined ##java[08:36:16] *** idea4good has quit IRC[08:36:43] <ckebabo> which case throws exception, which case returns error? where can i find relative document?[08:37:53] *** zeno___ has left ##java[08:40:17] <cybereal> ckebabo: nobody has any idea wtf you're talking about[08:40:40] *** rlubke has left ##java[08:40:58] *** convivial has quit IRC[08:41:10] *** __simon__ has joined ##java[08:42:27] <ckebabo> i guesss nobody is here. heh. :([08:42:47] <cybereal> you asked a nonsensical context-less question[08:42:51] <cybereal> why would anyone answer?[08:45:59] <svm_invictvs> ugh[08:46:05] <svm_invictvs> I just got thrown out of a bar like a bad exception.[08:46:09] <[[thufir]]> the context fails to validate: Cannot find the declaration of element 'Context'. http://pastebin.com/m69180824 but, to my eyes, the syntax looks fine.[08:46:32] *** Ephidaurus has joined ##java[08:46:48] <cybereal> [[thufir]]: you've got no dtd or schema associated with that xml document[08:47:15] <[[thufir]]> ok. I'm not sure how to proceed, but at least I know the problem now.[08:47:25] <cybereal> basically everything is invalid heh[08:48:02] <cybereal> either you'll add a doctype definition or you'll associated a schema with the default namespace, probably you can find an example of another config out there doing this[08:48:51] <[[thufir]]> thanks, yes, I'm googling.[08:50:33] *** gdoko has joined ##java[08:51:43] *** spackest has joined ##java[08:51:57] *** spackest has left ##java[08:53:53] <cybereal> [[thufir]]: hey I'm finding information that indicates that server.xml and related xml sub documents can not be validated[08:53:58] <cybereal> because their structure is not defined[08:54:03] <cybereal> it's implementation specific[08:54:32] *** ilaggoodly has joined ##java[08:55:13] <[[thufir]]> cybereal: can you give me the link? I'm getting runtime errors saying to fix this doc[08:55:25] <cybereal> runtime errors from what?[08:55:30] <pstickne> fix it. fix it. fix it.[08:55:37] <cybereal> http://wiki.apache.org/tomcat/FAQ/Miscellaneous#Q10[08:55:38] <[[thufir]]> :)[08:56:22] *** chriswk_ has joined ##java[08:58:40] *** CrypticSquared has quit IRC[08:59:56] *** squi has joined ##java[08:59:57] *** boringwall has quit IRC[09:00:33] <cybereal> is it tomcat that's giving you that or is this some misguided attempt by netbeans to validate all of your xml in your project?[09:01:01] *** Resistance has quit IRC[09:01:24] *** Resistance has joined ##java[09:01:27] *** Csow has quit IRC[09:02:02] *** deSilva has joined ##java[09:03:47] *** CaneToad has joined ##java[09:04:29] <[[thufir]]> I think it's tomcat. it's after the build. I don't see how netbeans could or would give that error. I'll post it.[09:05:46] *** bhz- has quit IRC[09:05:57] <CaneToad> anyone know the java jaxb markup required for java's wsgen to recognise a List<something> within a type?[09:06:47] <CaneToad> @XmlElement(name = "LineItem", required = true) protected List<LineItem> lineItem; is not enough...wsgen ignores it[09:07:04] *** TheCastor has joined ##java[09:07:14] <cybereal> [[thufir]]: run your code without netbeans involved[09:07:38] <cybereal> [[thufir]]: it's rather easy to see how netbeans would or could give that error, everything about your output looks like standalone validation tool's output[09:07:40] <[[thufir]]> cybereal: yeah, I'm starting to agree with that.[09:08:32] *** dpy has joined ##java[09:09:18] *** ldamwork has joined ##java[09:09:18] *** CrypticSquared has joined ##java[09:09:39] *** ffgeek200b has joined ##java[09:09:41] *** ffgeek200 has quit IRC[09:10:28] *** vengfulsquirrel has joined ##java[09:10:50] *** TranceControl has joined ##java[09:12:48] *** skoskav has joined ##java[09:13:09] *** hatchetman82 has joined ##java[09:14:21] <hatchetman82> anyone know of any good guildes to http components ? almost everything i dig up online refers to the previous incarnation (when it was under commons)[09:14:38] *** ldam has quit IRC[09:15:51] <[[thufir]]> httpcomponents?[09:17:03] *** pierrep has joined ##java[09:20:19] <pstickne> mmm.[09:20:46] <pstickne> does anyone know a good place to get the EJB classes without having to wander through Sun's bullshit Glassfish or JBoss downloads?[09:22:58] <[[thufir]]> cybereal: it's confirmed that the error isn't caused by server.xml not having a schema, or being invalid, btw. thanks.[09:26:14] *** CrypticSquared has quit IRC[09:26:58] *** CaneToad has quit IRC[09:28:40] *** ldamwork has quit IRC[09:29:18] *** xiven has joined ##java[09:29:49] <hatchetman82> pstickne : you mean the ejb3-spec jar ? (thats available from a maven repository near you) or an EJB3 reference ? (in which case you'll need to dig into an implementation, like glassfish' jboss; openEJB, whatever)[09:30:08] *** repnop has joined ##java[09:30:16] <hatchetman82> err ... i meant reference = implementation*[09:30:30] *** pirx_ has joined ##java[09:30:55] <pstickne> hatchetman82: no idea what all this nonsense is. I just ended up taking java-ee-whatever from openejb[09:30:57] <hatchetman82> thufir : their site covers mostly the http core part, with the only "guide" to the http client component being the example code[09:31:31] <pirx_> hi! trying to install jdk_6u12 on linux. i get: "/usr/share/mobical-installer/DATA/sun_java/jdk-6u12-linux-i586.bin: 474: ./install.sfx.8020: not found". did a checksum on the file and it looks ok. what could be the cause?[09:31:40] <hatchetman82> pstickne: EJB3 is a spec, its just a few interface classes and a bunch of documants saying how things _should_ work[09:31:57] *** azanar has joined ##java[09:32:03] <pstickne> hatchetman82: then I guess I grabbed the right thing :)[09:32:09] <hatchetman82> anyone is free to implement this spec (meaning to write an actual application that behaves like the documents say)[09:32:18] <pstickne> hatchetman82: thanks[09:32:55] <hatchetman82> yes and no. you'll be a lot closer to practicin on the "real thing" if you get glassfish or jboss[09:33:04] <hatchetman82> (at least the reallity in which i work)[09:33:16] <hatchetman82> practicing*[09:33:41] <hatchetman82> ....although for simple "hello world" things anything will work[09:34:05] <pstickne> hatchetman82: openejb doesn't count? :([09:34:45] <pstickne> I guess I also lose points for wanting to use cayenne over hibernate ...[09:34:51] <hatchetman82> its an implementation of EJB, its just that in ... err ... "real life" you mostly dont see it, but you get a full blown production server running EJB3 + a bunch of other things (like jboss)[09:35:14] <pstickne> bah :)[09:35:28] <pstickne> I'm using Jetty + LiftWeb + OpenEJB + (???) :-)[09:35:39] <hatchetman82> going the lean and mean route ?[09:35:41] <hatchetman82> :-)[09:36:12] <pstickne> Just playing around mostly. I'm using EJB mostly because it's a "requirement" for this course. Otherwise I'd like to play with other distributed systems...[09:36:24] *** ldam has joined ##java[09:37:03] <pstickne> Thankfully EJB3 is about these days... last time I looked at it (which was a very long time ago) it was EJB2 (or still 1x?) ... *sigh*[09:37:08] *** azanar has quit IRC[09:44:14] *** CrypticSquared has joined ##java[09:44:25] *** Dr_Link has quit IRC[09:45:12] *** Tempoe has quit IRC[09:45:24] <neshaug> I'm using jasperreports, and in my report I use the sortField tag to sort.. (doh'), but I need the sortField to only kick in when some parameter is set to true, any good suggestion on how to achieve this?[09:45:36] *** azanar has joined ##java[09:49:10] *** vengfulsquirrel has quit IRC[09:49:38] *** idea4good has joined ##java[09:49:57] *** marvi has joined ##java[09:50:42] *** thpar has joined ##java[09:51:56] *** warriorforgod has quit IRC[09:52:05] *** teralaser has joined ##java[09:52:09] *** valcker has joined ##java[09:54:54] *** Wicked has quit IRC[09:55:20] *** acuster has quit IRC[09:56:26] *** pidus has joined ##java[09:57:23] *** acuster has joined ##java[09:58:36] *** mmc has joined ##java[09:59:35] *** idea4good has quit IRC[10:01:06] *** acuster has quit IRC[10:02:42] *** xiven has left ##java[10:02:56] *** kungen has joined ##java[10:04:08] *** lilako has quit IRC[10:04:13] <pidus> I fill in text from a file on JTextPane using read() method but once i do that a DocumentListener which i associated with the JTextPane in the class constructor stops listening to events. The DocumentListener works fine if I type text in the original JTextPane. Can anybody tell me what could have resulted in the DocumentListener not getting triggered, later?[10:05:14] *** CrypticSquared has quit IRC[10:05:23] *** ilaggoodly has quit IRC[10:07:28] *** acuster has joined ##java[10:07:49] *** ilyak has joined ##java[10:07:53] <ilyak> hi *[10:11:02] *** pstickne has quit IRC[10:11:11] *** MigoMipo has joined ##java[10:11:50] * mocas morning[10:12:07] *** Sikul has joined ##java[10:12:51] *** Jonny_ has joined ##java[10:12:56] *** Jonny_ is now known as Jonny[10:15:34] *** mazzachre has joined ##java[10:15:48] *** juc0 has joined ##java[10:16:44] <mazzachre> Is XPP dead?[10:18:22] <cybereal> XPP?[10:18:39] <mazzachre> Xml Pull Parser[10:18:42] *** staar2 has joined ##java[10:18:44] <cybereal> ~stax[10:18:44] <javabot> cybereal, stax is the Streaming API for XML: see ~jsr 173 and https://sjsxp.dev.java.net/ for Java 1.5 and earlier. Java 1.6 includes an implementation in the JDK.[10:18:55] <cybereal> stax is a pull parser[10:18:59] <mazzachre> ok[10:19:09] <cybereal> and it's basically a standard now so I'd guess any competitors have mostly died off[10:20:27] <cybereal> stax's best feature is that it's bidirectional[10:20:32] <cybereal> you can use it to construct xml too[10:21:27] <mazzachre> OK.. So that is what I am going to use :) And it is included in 1.6, which we use anyways...[10:21:42] * mazzachre erasing memory of xpp :)[10:21:46] * svm_invictvs pets proguard[10:22:01] <mazzachre> Ya..[10:22:39] <mazzachre> Is there a nice std. way to serialize objects to XML in a schematizied way with namespaces?[10:25:20] <cybereal> well there is a standard way for beans, with XMLSerializer not sure it meets your requirements, then there are some tools like jaxb which will work with whatever schema you define (not sure about namespaces but probably) and also castor is pretty flexible I'd look at that too[10:26:07] *** bhz- has joined ##java[10:26:33] *** fr0ggler has joined ##java[10:27:04] *** shervin_a has joined ##java[10:28:32] *** Aquanox has quit IRC[10:29:33] <mazzachre> The objects (and inherited/extended objects) are basically beans... And could be made into std. beans with little efford (We are still designing...)[10:29:57] <cybereal> oh I forgot to mention xstream as another option, still not sure about namespaces[10:29:59] <cybereal> ~xstream[10:29:59] <javabot> XStream is a simple library to serialize objects to XML and back again. It can be found at http://xstream.codehaus.org[10:32:58] *** rawblem has joined ##java[10:33:47] *** KU0N has joined ##java[10:36:59] *** ridoo has joined ##java[10:37:00] *** spuz has quit IRC[10:37:12] *** KermitTheFragger has joined ##java[10:38:08] *** mblp has joined ##java[10:39:27] *** `House` has joined ##java[10:39:37] *** CrypticSquared has joined ##java[10:40:27] *** rawblem has quit IRC[10:40:33] <mblp> hey everyone, just a quick conceptual question. i am new to java and have been working on a little gui app using swing. sometimes i find it nesscessary to show/hide frames, add to lists (using defaultmodel) and the like and did/do so by declaring certain things "static" (such as JFrame, so i can set the visibility anywhere in my code) -- my colleagues refer to this as "sloppy". i am struggling to figure out how to manipulate things such as fr[10:40:33] <mblp> ames that are defined in a method from the "outside" (in the actionlistener, for example)[10:41:04] <mblp> without using static "declarations" occasionally[10:41:57] <mblp> i understand how to use inheritance to reduce code, like making a class extend actionlistener and point everything to the method there.[10:42:18] <mblp> but not really how to manipulate values from the "outside". thanks.[10:43:06] *** KikiJiki has joined ##java[10:43:14] *** Resistance has quit IRC[10:45:15] *** doc`` has quit IRC[10:46:26] *** bas-i has joined ##java[10:51:15] *** mblp has quit IRC[10:51:50] *** Bevin has joined ##java[10:55:38] *** maco has joined ##java[10:55:53] *** nijm has joined ##java[10:56:01] <maco> is there anything in swing thats like those little calendars that pop out of combo boxes so you can choose a date?[10:56:59] *** __simon__ has quit IRC[10:57:25] <hatchetman82> maco : tried looking at swingx ?[10:57:31] <hatchetman82> ~swingx[10:57:32] <javabot> hatchetman82, swingx is the SwingLabs Swing Component Extensions Library -- https://swingx.dev.java.net[10:57:34] *** cher has joined ##java[10:57:43] <maco> ah i forgot that existed[10:57:44] * hatchetman82 loves the bot[10:57:50] <maco> thanks[10:57:54] <hatchetman82> np[10:58:01] *** giaco has joined ##java[10:59:17] *** marvi has quit IRC[10:59:39] <maco> hm wait is swingx the same as javax.swing?[10:59:40] *** tissue_al has joined ##java[10:59:52] *** vara2009 has quit IRC[11:00:23] *** vara2009 has joined ##java[11:01:01] *** LouisJB1 has joined ##java[11:01:20] <maco> hatchetman82: is swingx the same as javax.swing?[11:01:21] *** pidus has left ##java[11:01:31] <hatchetman82> no[11:02:01] <hatchetman82> a long time ago swing itself was new so they put it in javaXtensions[11:02:13] *** nijm has quit IRC[11:02:23] <hatchetman82> swingx produces 3rd party components that usually extend swing components (found in javax.swing).[11:02:31] <maco> ok[11:02:50] <hatchetman82> swingx uses org.jdesktop or org.swinglabs dont remember which[11:03:05] <hatchetman82> its a jar you need to download and add to your project[11:03:45] <maco> O_o there's a org.CORBA...is that CORBA as in the thing that was heavily embedded into Evolution, the GNOME mail client?[11:03:52] *** justafish has joined ##java[11:03:57] <ilyak> yeah[11:04:01] <ilyak> and it also does suck[11:04:09] <maco> hence the O_o[11:04:26] <maco> i think they finally ripped all the CORBA and bonobo stuff out of evo[11:04:36] <ilyak> yeah[11:04:45] <maco> it actually *gasp* fits into the rest of gnome now[11:05:42] <cybereal> people actually use that? I thought it was an entry into a contest to see if anyone could make an even worse mail client than outlook 2000[11:06:14] <maco> i like evolution actually...or at least, i like evolution-data-server...mostly because of what it does to the Clock applet[11:06:48] <maco> kmail is capable of properly deleting emails from gmail imap, however...[11:07:17] <maco> which really just means i need to learn some C++ and make the clock plasmoid do the same thing that the gnome clock applet does[11:07:36] <cybereal> I've only ever liked two mail clients, Mail.app on Mac OS X and Sylpheed[11:08:03] * ilyak has really liked The Bat!, however it had its problems[11:08:08] *** acuster has quit IRC[11:08:15] <ilyak> but they were the only client who cared about threading and got it right[11:08:16] <maco> the combination of kmail, korganizer, and kaddressbook is very similar to combining Mail.app, iCal, and AddressBook, so....[11:08:25] *** Daniel_H has joined ##java[11:08:25] <maco> but yeah, Apple's combo is the holy grail[11:08:26] <ilyak> most clients (including kmail and thunderbird) don't care[11:08:39] <cybereal> ilyak: mail.app does threading better than anything I've used...[11:08:50] <ilyak> cybereal: I've yet to work on a mac[11:08:52] <cybereal> and offers lots of ways to interact with it besides just hierarchical display[11:08:57] <maco> ive no idea about the threading, just thinking of the ways to use it[11:09:22] <cybereal> I did like kmail most of the time back when I was a linux zealot[11:09:28] <maco> kontact sealed the deal when i accepted an invite in an email in kmail and korganizer automatically put it on the calendar...just like Mail.app & iCal would[11:09:40] <maco> evolution's not that smart[11:09:41] <ilyak> kmail is fine but it has a few irritations[11:09:57] <maco> kmail in kde 4.2 crashes a LOT[11:10:01] *** IRAQI` has joined ##java[11:10:21] <maco> delete a thread? crash. set your pgp key? crash.[11:10:36] *** mosno has joined ##java[11:10:38] <ilyak> First, they didn't get the threading right; second, they didn't get the search right (did I say The Bat!'s search ruled the world), and also it have a pack of Shlemiel the Painter's algorithms inside[11:10:57] <Stephmw> mornin'[11:11:01] <ilyak> Like, deleting 50000 messages takes a half hour[11:11:13] <maco> ilyak: its currently not possible[11:11:24] <maco> deleting 3 messages simultaneously will crash it[11:11:47] <ilyak> maco: I'm yet to see KDE4 either[11:11:51] <ilyak> I'm still on KDE3[11:12:15] <maco> 4.0 was rough. 4.2 is pretty, and polished and whatnot, buuuuuut...little details are missing[11:12:36] *** tissue has quit IRC[11:12:38] <maco> like what's there is good, but there are little "would be nice if..." things that gnome already has[11:13:02] <maco> like, in gnome you can change the panel background without having to recompile the panel[11:13:12] *** Resistance has joined ##java[11:13:29] *** dpy has quit IRC[11:13:35] <ilyak> I use kde-apps mostly so gnome is no chils[11:13:38] <ilyak> choice*[11:13:46] <maco> i use gnome apps inside kde :P[11:13:51] *** dpy has joined ##java[11:14:05] <ilyak> I use amarok, akregator, konqueror, k3b from time to time[11:14:21] *** nijm has joined ##java[11:14:22] <maco> oh yeah i did start using amarok[11:18:56] <maco> does Calendar replace Date?[11:19:53] <maco> bah java seems so foreign after you spend all your time staring at C/GTK+ and the linux kernel[11:21:29] <maco> or assembly...[11:21:38] *** whaley has joined ##java[11:22:34] *** davo has quit IRC[11:24:25] <ilyak> No it doesn't[11:24:29] <ilyak> It's a separate class[11:24:39] <ilyak> But if you want sane time handling, then[11:24:43] <ilyak> ~~maco joda-time[11:24:44] <javabot> maco, joda is an excellent date/time implementation for Java. http://joda-time.sourceforge.net - also JSR 310 - https://jsr-310.dev.java.net/[11:24:47] <maco> im looking at the list of deprecated functions[11:24:48] *** krad has joined ##java[11:24:57] <krad> hi. Is String converted to StringBuffer at compile time?[11:25:16] <ilyak> krad: Uhm, which one?[11:25:18] *** mosno is now known as cousin_mario[11:25:26] <krad> ilyak: String class[11:25:33] <whaley> krad: no[11:25:35] <ilyak> Of course it isn't[11:25:42] <krad> then converted to what?[11:25:48] <whaley> krad: it isn't converted to anything[11:25:51] <fr0ggler> nothing[11:25:52] <ilyak> Well, it's just a String[11:25:54] <fr0ggler> it's a string[11:25:55] <krad> if you do +=[11:25:56] <whaley> krad: a String is a String is a Strig[11:25:57] <maco> im not sure about using not-in-main-swing stuff since this is for school. i dont think the program really has to *work* since it's for a UI class...but eh. thats why i was looking for a calendar widget...because every other toolkit has one and they just plain make sense[11:26:14] <krad> x += "hi"; x+="tst";[11:26:19] <krad> and x is of type String[11:26:23] <ilyak> krad: It might be[11:26:36] <whaley> krad: a StringBuilder(Buffer?) gets in that case behind the scenes, but x will still always be a String in your bytecode[11:26:40] <krad> but i want to know in that case. it gets converted to StringBuffer or StringBuilder?[11:26:41] <maco> i *think* its one of those classes where open source libraries are ok, but im not sure[11:26:42] <whaley> *gets used[11:26:53] *** cousin_mario is now known as mosno[11:27:33] *** mosno has quit IRC[11:28:00] *** rawblem has joined ##java[11:28:56] <whaley> krad: x += "tst"; turns into new StringBuilder(x).append("tst").toString(); iirc[11:29:36] <krad> whaley: but in that case StringBuffer isn't used in any way[11:30:18] <maco> huh that's interesting. SwingX is "all right reserved" but licensed under the GPL[11:30:44] <whaley> http://forums.sun.com/thread.jspa?threadID=5210952[11:30:56] <whaley> krad: apparently not[11:32:23] <[[thufir]]> will a war run exactly the same on glassfish as it does on tomcat? no, right? each container has its peculiarities?[11:32:25] <maco> hatchetman82: do i need just the swingx .jar or do i need the swingx-bean .jar and the ones in /lib as well?[11:32:44] <hatchetman82> ....good question.[11:33:00] <hatchetman82> mostly i rely on maven for these things. do you use maven ?[11:33:04] <maco> no[11:33:06] <hatchetman82> if so, just add teh dependency.[11:33:10] <maco> i dont really do much java[11:33:28] <hatchetman82> if not, i'd try just 1 jar, and if things dont compile / throw a ClassDefnotFound, add the others[11:33:39] <maco> i have to turn it into my prof. im pretty sure this is a "open source libs are fine" class...he basically just requires that there's some way to run it on his mac[11:33:57] <hatchetman82> so just add all of them and be done with it :-)[11:34:13] <hatchetman82> unless youre graded for bloat[11:34:46] *** Level1 has quit IRC[11:34:47] <whaley> [[thufir]]: in theory, yes[11:35:54] *** pidus has joined ##java[11:36:29] <maco> hatchetman82: nah its just UI design[11:36:37] <hatchetman82> [[thufir]]: if yuo stick strictly to whats covered under the various official specs (like avoid the HA-JNDI tree on jboss etc) then yes[11:36:43] <pidus> how can i identify a nameless jbutton in an actionlistener?[11:38:37] <pidus> I mean, how can i figure out which JButton was pressed if the button is unnamed, from ActionEvent?[11:38:40] *** rawblem has quit IRC[11:39:16] <hatchetman82> ideally, if all the code is yours, the simple answer would be name all of them and dont get into it[11:39:30] <ldam> pidus, check the api for the event. It has some event source you can use[11:39:56] <hatchetman82> you could always try traversing the GUI structure around your button and see "where" it is (what panel ? what row in the table ? hints)[11:40:14] *** mbroeker has joined ##java[11:40:26] <pidus> hatchetman82: since my button is an image, i don't want any text to appear with it[11:40:47] *** ChanServ has quit IRC[11:41:19] *** ChanServ has joined ##java[11:41:19] *** irc.freenode.net sets mode: +o ChanServ[11:41:23] *** cybereal has quit IRC[11:41:29] <ldam> pidus, check the api for what i said, dont listen to hatchetman82[11:41:40] <hatchetman82> :-)[11:41:42] <pidus> ldam: ok[11:41:50] *** chriswk_ has quit IRC[11:41:59] <pidus> ldam: you mean the JButton api?[11:42:12] <hatchetman82> ActionEvent, i think[11:42:26] <ldam> pidus, i said 'event'... Which in your case probably is the ActionEvent[11:44:41] *** chriswk_ has joined ##java[11:45:13] *** Level1 has joined ##java[11:45:26] *** gabbah has joined ##java[11:46:36] <gabbah> does anyone else have massive problems doing any updating in eclipse at the moment? Through the software update dialogue?[11:47:17] *** JohnBat26 has joined ##java[11:47:18] *** azanar has quit IRC[11:48:35] *** azanar has joined ##java[11:51:25] *** nvictor has joined ##java[11:51:47] *** nvictor has left ##java[11:53:39] *** nijm has quit IRC[11:55:54] *** gizmola has quit IRC[11:58:20] *** acuster has joined ##java[11:58:58] <siyb> http://www.evilmilk.com/pictures/Vibrators.jpg[11:59:30] <siyb> sorry wrong channel[11:59:30] <siyb> ...[12:03:25] *** wans has joined ##java[12:03:29] <wans> Hi[12:03:41] <staar2> arrays could be represented like ... ?[12:03:49] <staar2> String... args ?[12:04:29] <wans> have anyone dealth with Images here before? Im having a problem with java.awt.image.BufferedImage.getRGB();[12:04:38] *** skoskav has quit IRC[12:04:40] *** jerkface03 has quit IRC[12:05:23] <wans> Documentation says this int getRGB(int x, int y)[12:05:48] *** BW^- has quit IRC[12:06:17] <wans> when im trying to display the value of a pixel im getting these kind number; -16711936[12:06:38] *** pidus has quit IRC[12:06:47] *** FMJaguar has quit IRC[12:07:00] *** jerkface03 has joined ##java[12:11:18] *** dnmo has joined ##java[12:11:53] *** hatchetman82 has quit IRC[12:17:33] *** orgy` has joined ##java[12:20:16] *** CrypticSquared has quit IRC[12:21:25] *** bas-i has quit IRC[12:23:07] <jottinger> morning[12:25:18] *** asap18 has joined ##java[12:25:28] <Ragnor> hi[12:25:38] *** Sonderblade has joined ##java[12:26:30] <Sonderblade> in jpa, if you make an integer @Column nullable=false, can it still contain the value 0?[12:27:38] <jottinger> is 0 a non-null value?[12:28:30] <wans> ~getRGB()[12:28:31] <javabot> wans, I have no idea what getRGB() is.[12:28:37] <Sonderblade> the answer is maybe[12:28:52] <wans> ~BufferedImage[12:28:52] <javabot> wans, I have no idea what BufferedImage is.[12:28:52] <jottinger> okay. Are you using JPA with C?[12:30:04] *** sombriks has joined ##java[12:30:45] <Sonderblade> no with mysql[12:31:29] <jottinger> does mysql treat 0 as null?[12:33:41] *** JohnBat26 has quit IRC[12:33:47] *** JohnBat26 has joined ##java[12:33:49] <ilyak> lol[12:33:56] *** elliottcable has quit IRC[12:34:08] <ilyak> jottinger: http://sqlanywhere.blogspot.com/2008/03/unpublished-mysql-faq.html[12:34:08] *** elliottcable has joined ##Java[12:34:46] *** bas-i has joined ##java[12:37:36] <jottinger> ilyak: I don't care, I'm asking Sonderblade[12:37:46] *** arpu has quit IRC[12:37:47] <jottinger> I'm not normally a user of mysql[12:41:08] <gabbah> wtf... I'm doing scjp quesitons, and I have one about the hashcode and equals contract which I don't agree with: "Given two objects a and b of the same class, and if equals() and hashCode() are implemented correctly for that class, which of the following must hold t"rue?" - and the answer is "if a.hashcode() != b.hashcode then !a.equals(b)[12:41:39] <jottinger> they're not equal if the hashcodes aren't equal[12:41:47] <jottinger> they can not be equal even if the hashcodes ARE the same[12:41:56] *** tissue has joined ##java[12:41:58] <jottinger> but if the hashcodes are different, they're definitely not equal[12:42:11] <benJIman> Unless you've implemented one of them wrongly :p[12:42:11] <gabbah> hmm yeah that's true[12:42:46] <gabbah> i don't know what i was thinking :/[12:44:48] *** skoskav has joined ##java[12:45:05] <jottinger> j #bloodfrontier[12:45:10] *** ofl_ has joined ##java[12:45:41] *** hrad has joined ##java[12:45:49] <jottinger> sorry, missed a / :([12:45:52] *** ckebabo has quit IRC[12:45:54] <hrad> hi, I'm doing some web services with axis and I'm getting the warnings about missing activation and mail libraries[12:46:05] <hrad> in eclipse on tomcat[12:46:09] <hrad> any ideas please ?[12:46:19] <jottinger> supply the missing activation and mail libraries[12:46:40] <hrad> yes but from where to where[12:46:50] <jottinger> where is axis in your app?[12:47:00] <jottinger> Is it part of your app? (i.e., WEB-INF/lib?)[12:48:11] <hrad> jottinger,[12:48:11] <hrad> no[12:48:19] <jottinger> so where... is... it?[12:48:26] * jottinger hates questions like this[12:48:31] <gabbah> not knowing alot about that, i got the same error some time ago. i just placed some activation and mail jars in tomcat lib folder, and then it was happy[12:48:52] <jottinger> gabbah: that might be the right place for him[12:49:24] <jottinger> but it still depends on where axis is[12:49:34] <hrad> I have just axis.jar library imported[12:49:52] <gabbah> i don't know, but anytime you miss some jars you can put them there. that might be bad "design" though.. only shared stuff like mail should be placed there i guess[12:49:56] <jottinger> activation and mail go alongside axis, so if axis is in his app, activation.jar and mail.jar should be too[12:50:10] <hrad> ok, thank you[12:50:14] <gabbah> in the application jar u mean? not in tomcat lib?[12:50:30] <jottinger> gabbah: right, unless he intends for them to be shared, which is what you did[12:51:38] *** armyriad has quit IRC[12:52:27] *** JohnBat26 has quit IRC[12:52:34] <hrad> I put it into the Web App libraries[12:52:40] *** JohnBat26 has joined ##java[12:53:48] <hrad> so it should put a reference for WEB-INF/lib and classes[12:54:44] *** tissue_al has quit IRC[12:54:48] *** bitshuffler has joined ##java[12:58:21] *** Resistance has quit IRC[12:58:55] *** bigjocker has joined ##java[13:01:12] *** nijm has joined ##java[13:02:04] *** IRAQI` has quit IRC[13:02:56] <jottinger> wans: just out of an interest for teh world to be filled with politeness, butterflies, unicorns, fairies, and nice chairs, might I suggest that you not try to hunt down someone who's "done graphics with java" on irc?[13:03:05] <jottinger> Ask your question - a real question - and move on[13:04:01] <wans> but ive tried it before[13:04:05] <wans> ok here we go[13:04:41] *** vezzoni has joined ##java[13:05:17] <jottinger> wans: if you don't get an answer, then either people don't know, or they aren't here, or they're not interested[13:05:24] <jottinger> none of those are things you can change[13:06:30] *** Bevin has quit IRC[13:06:59] <jottinger> that's not to say you shouldn't ask - but it just addresses what you can do about an answer and your expectations for one[13:08:05] *** brilliantnut has quit IRC[13:08:06] *** musically_ut has quit IRC[13:08:07] <jottinger> wans: oh[13:08:17] <jottinger> wans: getRGB returns an int, right?[13:08:18] *** t432 has joined ##java[13:08:50] *** acuster has quit IRC[13:08:54] *** brilliantnut has joined ##java[13:09:42] *** hrad has quit IRC[13:09:56] <Sonderblade> jottinger: see the link ilyak posted, mysql is crap which is why i need many annotations in the jpa layer to keep data integrity[13:10:11] <t432> Hey folks ... I just had an technical telephone interview with quite reputable company ... I am trying to land a face to face interview based on the information got from the interviewer they are looking for someone who can perform automated tests, test cases etc, what can say to convince them they should invote me for another interview ?[13:10:40] <t432> invite*[13:11:22] <t432> I am looking for something I can tell them about test situations that will impress them[13:11:24] <jottinger> Sonderblade: sure. Why do you think I don't use mysql often?[13:11:42] <jottinger> t432: Have you written automated tests?[13:11:54] <jottinger> What kind of automated tests are you talking about?[13:12:07] <Sonderblade> jottinger: because you are asking lots of stupid counter questions instead of answering my question which was a simple YES OR NO![13:12:13] <t432> jottinger: To be honest,,, No[13:12:19] <jottinger> Sonderblade: Socratic method.[13:12:31] <jottinger> t432: so what kind of testing are they doing? Are they just testing code?[13:12:44] * Sonderblade gives jottinger some poison to drink[13:12:52] <jottinger> Sonderblade: and the answers determine YOUR answer.[13:12:58] <t432> jottinger: well the position I applied for was a software engineer so I guess its code[13:13:12] <jottinger> if MySQL treats 0 as null, well... that's not only horribly broken, but then isNull would prevent 0 too[13:13:20] <jottinger> t432: so have you ever used junit, testng?[13:13:40] <jottinger> know the difference between unit, module, system testing?[13:13:47] <t432> I came across JUnit but I havent used it no[13:13:49] *** l3ns has quit IRC[13:13:56] <reverend> haha[13:14:11] <jottinger> t432: ever written tests apart from junit?[13:14:13] *** hrehf has joined ##java[13:14:31] <jottinger> these are quick questions, man, spit out answers[13:14:37] <wans> yes jottinger getRGB() returns an int and uses color model (TYPE_INT_ARGB) ifs not defined so, 8-bit Red 8-bit Green 8-bit Blue and 8-bit Alpha[13:14:50] <t432> jottinger: I have writtern standard test cases e.g. to see if a method or a class is doing what it supposed to do thats it[13:15:07] <reverend> t432: you should say something like 'hmm, this new thing called 'testing' interests me greatly, i would be happy to disuss the concept further with you'[13:15:09] <jottinger> wans: so there you go. Your int is a representation of those. convert to hex and you'll have your 8-bit values.[13:15:22] <jottinger> t432: how did you execute those test cases?[13:15:26] <jottinger> ever use fitnesse?[13:15:35] <t432> erm no[13:15:40] * jottinger is always looking for someone who's used fitnesse in the wild[13:15:48] <jottinger> ... so I can make fun of them :)[13:15:58] <t432> fitnesse ... I'll take a note of that[13:16:03] <t432> lol[13:16:05] <jottinger> don't, it's not likely to be relevant[13:16:21] <reverend> i would suggest that any reasonably clued up technical interviewer might eat t432 alive[13:16:29] <jottinger> but junit is, and your unfamiliarity with it or testng is likely to be a concern if the company is in the year 2006 or later[13:16:47] <jottinger> reverend: sure, but let's be real... clued-up tech interviewer?[13:16:55] <reverend> i've had them[13:17:14] <t432> well I am writing a thank you letter to the interviewer ... what do you suggest I put in the letter to convince them I can perform tests ... I can always pick these skills up before the actual interview[13:17:17] *** floe has joined ##java[13:17:18] <jottinger> reverend: BTW, my new $employer - the likely one - is not only geographically close to you but hired me because they're just now looking at things like junit, etc[13:17:41] <wans> ok jottinger but i only want to know if the image has any pixel with this value, 255,0,0,0. Could i switch the int to hex and then get just the first 8 bits?[13:17:54] <jottinger> reverend: I've had them too, but I've ALSO had a lot of tech interviews that go like this: "So, mr. jottinger... your resume has spring on it. Do you know Spring?"[13:18:13] *** BeholdMyGlory has joined ##java[13:18:13] <jottinger> wans: sure, but why not just get the first 8 bits and ignore the hex part?[13:18:30] <jottinger> s/hired/will have hired/[13:18:41] <Sonderblade> jottinger: duh, the interviewer is using the socratic method.[13:18:44] *** xabbuh has joined ##java[13:18:51] <reverend> t432: 'thank for your time today, i will look into the concepts in the job title i applied for so i can pretend i know what i'm doing at our next meeting. please excuse me in advance for wasting your time at our face to face interview'[13:19:02] <jottinger> Sonderblade: if the interviewer is using that level of questioning with me, it's not the right starting point.[13:19:34] <jottinger> t432: if you do actually really grok testing - you can learn junit functionally in a very short time. But you're kinda doomed.[13:19:44] *** KU0N has quit IRC[13:19:48] *** monkeycid has joined ##java[13:20:03] <t432> reverend: GO find something to constructive to do you moron ... you dont even have a clue what I am talking about[13:20:10] <jottinger> ...[13:20:13] <reverend> haha[13:20:15] *** ChanServ sets mode: +o jottinger[13:20:16] *** Copter has joined ##java[13:20:24] *** jottinger sets mode: +b *!*=anonymou@*.cable.ubr01.chwo.blueyonder.co.uk[13:20:25] *** t432 was kicked by jottinger (cluebat slipped and hit you on the way down.)[13:20:47] <reverend> aww. :([13:20:58] <Sonderblade> jottinger: the question is a test, he is actually asking you to _describe_ your spring experience[13:21:19] <jottinger> Sonderblade: anyone who doesn't know my spring experience isn't someone with whom I want to work[13:21:33] <jottinger> esp considering rod johnson is one of my references[13:21:33] *** buntfalke has joined ##java[13:21:42] <Sonderblade> jottinger: but he is formulating it as a yes or no question already asked to see if you are that socially inept that you answer "yes" and only "yes"[13:21:45] <jottinger> and he has the bestest name EVAR[13:22:01] <jottinger> Sonderblade: quite possible. I still choose to fail those interviews. :)[13:22:09] *** Aquanox has joined ##java[13:23:12] <Sonderblade> @jottinger: good for you, good luck :P[13:23:41] *** Level1 has quit IRC[13:25:24] <reverend> i've had a couple interviews that i knew i didn't want the job[13:25:32] *** jottinger sets mode: -b *!*=anonymou@*.cable.ubr01.chwo.blueyonder.co.uk[13:25:37] *** brousch has joined ##java[13:25:37] <reverend> based on what they were asking about[13:26:04] <reverend> i'm usually good about telling them if they call back though, unless i'm keeping it as a fallback[13:26:27] <reverend> 'i'm sorry, thanks for the follow up call, but i just don't think this would work out.'[13:26:55] *** nocture has quit IRC[13:27:37] <jottinger> Sonderblade: *shrug* I have two offers right now, in this economy, for very good positions[13:27:41] <reverend> usually those interviews contained questions like jottinger was complaining about[13:27:42] <cheeser> reverend: this is 2 days in a row that have begun with someone disparaging your age/experience.[13:27:45] <cheeser> 8^)=[13:27:48] <jottinger> and I've had interviewers *call me back* and apologize[13:27:55] *** magmarules has joined ##java[13:28:29] <reverend> cheeser: i'm on a roll[13:28:51] <cheeser> rick?[13:29:00] <magmarules> hello there, im having an existential crisis: the creation of DAOs. Is there an alternative to the DAOFactories with harcoded methods for each object ?[13:29:12] <cheeser> IoC[13:29:12] <reverend> i'm never gonna give cheeser up[13:29:32] <Stephmw> reverend: once you had cheese, you never go back[13:29:33] *** Junior has quit IRC[13:30:11] <Sonderblade> @jottinger: sorry. i wasn't sarcastic[13:30:36] <jottinger> Sonderblade: *shrug* it's okay[13:32:30] <jottinger> magmarules: use IOC[13:32:42] <jottinger> Spring calleth you. And if it doesn't calleth you, guice calleth you.[13:32:56] *** gdoko has quit IRC[13:35:01] <jottinger> or osgi calleth you.[13:35:04] <jottinger> SOMETHING.[13:35:16] *** brousch has quit IRC[13:37:03] *** veleno has joined ##java[13:37:52] <veleno> hello. anyone is aware of (any) internal changes to java.math.BigInteger between jdk1.5 and 1.6 ?[13:38:38] *** selckin has quit IRC[13:41:23] *** tom17bombadil has quit IRC[13:41:41] <reverend> veleno: why do you ask?[13:43:09] *** bitcrave has joined ##java[13:43:59] *** MigoMipo has quit IRC[13:44:36] *** r0bby has quit IRC[13:44:44] *** r0bby_ has joined ##java[13:48:11] <veleno> because of different behaviours of by tests[13:48:27] <cheeser> ~show us[13:48:28] <javabot> Paste the code (and any errors) in the pastebin where we can see it. See ~pastebin for options. Also see ~testcase for good examples as to how to help us help you quickly diagnose and solve problems.[13:49:43] <magmarules> Guys is there a way i can just do the following: call Class.forName(className); and convert to the returned type ?[13:50:08] <cheeser> you mean create a newInstance of that class?[13:50:43] <magmarules> cheeser: yeah and if it returns a TicketDAO make a cast to it[13:50:55] <magmarules> so that the code that requests it gets the requested type =)[13:50:58] <cheeser> ~javadoc Class[13:50:59] <javabot> cheeser: http://is.gd/ilcl [java.lang.Class][13:51:08] <magmarules> well got to go oki ty =)[13:51:15] * cheeser blinks[13:51:24] <reverend> magmarules: just use IOC ffs[13:51:36] <reverend> you aren't going to reinvent a better wheel here[13:51:59] *** morkar- has joined ##java[13:53:35] <reverend> wow RAD 7.5 is big[13:54:04] *** brousch has joined ##java[13:55:23] <cheeser> Rapidly Accreting Debris[13:57:38] *** bitshuffler_ has joined ##java[14:00:14] <reverend> methinks i might get me some coffee yo[14:01:01] *** claudio_ch has joined ##java[14:01:01] <gabbah> coffee! of course! why didn't i think of that![14:01:43] *** marvi has joined ##java[14:03:45] *** krad has quit IRC[14:06:58] *** RLa has joined ##java[14:07:27] *** [A2K] has joined ##java[14:07:59] <[A2K]> hello. are there some dynamic multi-dimensional arrays in java?[14:08:26] <ilyak> [A2K]: There are lists[14:08:31] <RLa> you could use arraylist, it bsically is[14:08:32] *** BW^- has joined ##java[14:08:41] <BW^-> does Java have any key-value kind of Arraylist type?[14:08:46] <RLa> arraylist of arraylists[14:08:53] <ilyak> ~~BW^- javadoc Map[14:08:55] <javabot> BW^-: http://is.gd/iHyZ [java.util.Map][14:08:57] <BW^-> arraylist of String[]:s?[14:08:58] <BW^-> right[14:09:27] <[A2K]> something like Arraylist<Arraylistr<int>> ?[14:09:34] <RLa> yes[14:09:51] *** maco has quit IRC[14:10:01] <marvi> I like the Collections API.[14:10:11] *** Bevin has joined ##java[14:10:14] <[A2K]> thanks[14:10:15] *** n3llyb0y has joined ##java[14:10:38] <marvi> [A2K]: The intro material is a good read: http://java.sun.com/j2se/1.5.0/docs/guide/collections/[14:10:41] <RLa> if you need some specific operatsions it's better to encpsulate those complex structures[14:10:58] *** monestri has joined ##java[14:11:06] <[A2K]> one more question. i use swing and want a simple spreadsheet. do i have to write model for JTable?[14:11:23] <RLa> yes[14:11:30] <RLa> it should be very easy[14:11:57] <marvi> [A2K]: or use an open source spreadsheet component.[14:12:21] <RLa> yes, do not reinvent the wheel[14:12:32] <RLa> if you need excel then just use excel[14:12:38] *** kungen has quit IRC[14:12:50] <marvi> Or buy a commercial component.[14:12:52] <[A2K]> ok, thanks[14:13:02] *** LostMonarch has joined ##java[14:13:32] <[A2K]> i don't really need such component, i am just learning java and it was interesting to me how to make a spreadsheet.[14:14:55] *** bitshuffler has quit IRC[14:14:56] <marvi> [A2K]: then you can look at how they implemented it.[14:15:45] *** [[thufir]] has quit IRC[14:15:55] *** skoskav has quit IRC[14:16:36] <RLa> or just use jtable to simply output some values, from db for example, not for full-blown spreadsheet calculator[14:22:40] *** FireSlash has joined ##java[14:24:20] *** Woot4Moo has joined ##java[14:25:11] *** aleksei has joined ##java[14:25:21] <aleksei> hello, hello... hola!!![14:27:07] *** LordMetroid has joined ##Java[14:27:34] *** squi has quit IRC[14:27:42] *** bashoh has quit IRC[14:29:09] *** hnr has quit IRC[14:30:05] *** squi has joined ##java[14:32:24] *** Resistance has joined ##java[14:33:06] *** mengu has joined ##java[14:33:34] *** popcornPanic has joined ##java[14:33:43] <gabbah> hola patron[14:34:09] *** Sid23 has quit IRC[14:37:40] <aleksei> hehe[14:38:06] *** squi has quit IRC[14:39:01] *** w0lfshad3 has joined ##java[14:39:15] *** claudio_ch has quit IRC[14:41:17] *** squi has joined ##java[14:43:08] *** rabby has joined ##java[14:43:11] <rabby> hi[14:43:29] <rabby> is there anyone here using jmagick?[14:43:55] <rabby> changing colors etc. runs very well, but i can not find a way to convert images e.g. from jpeg to gif :/[14:44:59] *** waz has joined ##java[14:45:46] *** cvasilak has joined ##java[14:46:30] *** acuster has joined ##java[14:46:46] *** JohnBat26 has quit IRC[14:48:43] *** asap18 has quit IRC[14:51:08] *** FireSlash has quit IRC[14:51:52] <cvasilak> hi there, one question is it possible with log4j to specify the encoding of the email sent Used log4j.appender.email.Encoding=UTF-8 but i am keep getting "Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit" I searched through the net but I am unable to find sth anyone have an idea?[14:53:04] *** nocture has joined ##java[14:53:26] *** Varox has joined ##java[14:54:46] *** giaco has quit IRC[14:55:11] *** giaco has joined ##java[14:55:52] *** tissue has quit IRC[14:59:50] *** floe has quit IRC[14:59:57] *** Frostix has joined ##java[15:02:55] *** dixie has joined ##java[15:05:29] <dixie> hi. I can't find over google details about meaning of "pc" in "wherei [<thread id> | all]-- dump a thread's stack, with pc info"[15:05:48] <dixie> in jdb help[15:06:05] <dixie> Do you have any idea ? :)[15:06:31] *** amitev has joined ##java[15:07:39] *** bitcrave has quit IRC[15:08:13] <dixie> Myabe it has something with "intruction Pointer" :)not sure...[15:10:19] *** eidolon has joined ##java[15:13:33] *** nijm has quit IRC[15:15:28] *** [TechGuy] has joined ##java[15:16:33] *** jdolan_ has joined ##java[15:17:08] *** JohnBat26 has joined ##java[15:17:15] *** gdoko has joined ##java[15:17:20] *** djp[mbp] has joined ##java[15:20:09] *** Frostix has quit IRC[15:20:49] *** cheeser has quit IRC[15:20:58] *** cheeser has joined ##java[15:20:58] *** ChanServ sets mode: +o cheeser[15:21:28] *** criminy has quit IRC[15:22:31] *** r0bby_ has quit IRC[15:22:41] *** Inc` has quit IRC[15:22:53] *** r0bby has joined ##java[15:26:17] <fr0ggler> dixie, probably JVM version etc?[15:26:33] *** nijm has joined ##java[15:26:42] *** RLa has quit IRC[15:27:59] <dmlloyd> pc may mean "program counter", which people call "instruction pointer" these days[15:28:26] *** Frostix has joined ##java[15:29:53] <dixie> thanks.[15:31:23] *** ankylose has joined ##java[15:32:59] *** ttmrichter_ has joined ##java[15:33:52] *** `House` has quit IRC[15:35:53] *** spathi has quit IRC[15:36:24] *** whaley has quit IRC[15:37:13] *** ttmrichter has quit IRC[15:37:35] *** Frostshock has joined ##java[15:37:58] <Frostshock> is it possible to pass a linked list as an argument to a static method?[15:38:02] <fr0ggler> dixie, ah sorry - i got the wrong end of the stick. don't use jdb much at all :)[15:38:27] *** bitcrave has joined ##java[15:38:59] <jottinger> fr0ggler: have you tried?[15:39:15] *** hrehf has quit IRC[15:39:24] <fr0ggler> Frostshock, i don't see why not...[15:39:30] <cheeser> ~~ Frostshock tias[15:39:30] <javabot> Try it and see. You learn much more by experimentation than by asking without having even tried.[15:39:31] <fr0ggler> jottinger, me?[15:39:42] <jottinger> errr... no, meant for Frostshock. tab completion misfire.[15:41:37] *** mele- has joined ##java[15:42:12] *** chriswk_ has quit IRC[15:44:03] <fr0ggler> completion misfire? sounds like you should go to a doctor to get that sorted :D[15:44:16] *** JanK has joined ##java[15:44:43] <JanK> is there a way to explicitly refer to a field in the enclosing class?[15:45:06] <Frostshock> seems like a tricky question :)[15:45:48] *** chriswk_ has joined ##java[15:46:07] <cheeser> OuterClass.field[15:47:51] <JanK> cheeser: that would be a static field?[15:48:16] <Frostshock> cheeser: im getting this error: cList.name cannot be resolved or is not a field[15:48:20] <cheeser> no.[15:48:44] <cheeser> LinkedList doesn't have name, Frostshock[15:49:28] <Frostshock> my method looks like this: static boolean findName(LinedList<NameList> cList) {[15:49:48] <Frostshock> and then i loop through the list with a for loop..[15:49:54] <fr0ggler> LinedList, not LinkedList?[15:50:07] <Frostshock> LinkedList.. sorry :)[15:50:23] <cheeser> fr0ggler: to seal in freshness![15:50:33] <fr0ggler> cheeser, woot![15:50:34] <cheeser> ~~ Frostshock show us[15:50:34] <javabot> Paste the code (and any errors) in the pastebin where we can see it. See ~pastebin for options. Also see ~testcase for good examples as to how to help us help you quickly diagnose and solve problems.[15:52:15] <Frostshock> ohhh...[15:52:25] *** ridoo has quit IRC[15:52:52] <Frostshock> solved it myself... i was trying to read the linked list and not the objects in it.. haha.. sorry[15:53:22] <cheeser> that's what I thought.[15:53:22] <cheeser> 8^)=[15:53:32] *** ridoo has joined ##java[15:53:43] *** chriswk_ has quit IRC[15:53:52] *** ffgeek200b has quit IRC[15:54:00] *** cheeser sets mode: -b *!*n=ionine@*.dyn.optonline.net[15:54:10] *** sasq has joined ##java[15:54:35] *** nijm has quit IRC[15:54:58] *** Copter has quit IRC[15:55:44] <sasq> Can anyone see the problem with this small antlr parser; http://rafb.net/p/kxVLkp24.html ?[15:56:00] *** developerhealey has joined ##java[15:57:02] *** Copter has joined ##java[15:57:51] *** CapriCoRN^80 has joined ##java[15:58:00] <CapriCoRN^80> hi[15:58:02] *** ThFabba has joined ##java[15:58:26] <CapriCoRN^80> cany anyone tell me how i can open my project in argouml[15:58:48] *** Copter has quit IRC[15:59:50] <fr0ggler> What's the proper definition for the method signature doSomething(Object...) ?[16:00:06] *** CapriCoRN^80 has quit IRC[16:01:16] *** Copter has joined ##java[16:01:48] *** chriswk has joined ##java[16:02:06] *** Angel-SL has quit IRC[16:02:34] *** Greyhound- has quit IRC[16:02:41] <fr0ggler> nevermind - it's varargs[16:02:50] *** Greyhound- has joined ##java[16:02:56] *** djp[mbp] has quit IRC[16:04:25] <JanK> cheeser: A.value doesnt work: http://pastie.textmate.org/private/daxmin0zcbtanausizkrjw[16:04:39] *** arpu has joined ##java[16:05:08] *** csgeek has joined ##java[16:05:15] *** BW^- has quit IRC[16:06:00] <JanK> its not really a problem, since i could just give the values a different name, but it bugs me, that i dont know how to explicitly refer to the enclosing var[16:07:15] *** skypce has joined ##java[16:07:15] *** eidolon has quit IRC[16:08:08] <cheeser> JanK: you're never referencing A.value[16:08:28] <JanK> cheeser: yep, since that gave me a compile error[16:08:28] *** vix85 has joined ##java[16:08:46] <JanK> non-static variable value cannot be referenced from a static context[16:09:10] <JanK> so the compiler read A.value as a static access[16:09:17] <JanK> *reads[16:09:51] <cheeser> JanK: then try showing *that* code and *that* error since what you showed was completely irrelevant[16:10:13] <JanK> http://pastie.textmate.org/private/ajppprf4gqr9h2qae8ig[16:10:33] <JanK> there you go[16:11:03] *** mele- has quit IRC[16:12:20] <magmarules> reverend: i have been reading on IoC and im thinking on using PicoContainer for dependencie management, i just needed to clarify somethink: so you add the DAOs into the PicoContainer, but for inter DAO dependency you have to put all the Dependent DAOs in the constructor, allong with the a Hibernate Session right ?[16:13:08] *** nocture has quit IRC[16:13:15] <cheeser> pico really? if you're not going to use spring, use guice[16:13:40] <cheeser> at least it's something someone else uses. i only hear of pico use in a historical context these days.[16:13:55] <reverend> magmarules: if you have dependencies that you need to inject, add them as properties of your DAO and configure them in your container config[16:13:57] <magmarules> lol ok[16:14:02] <reverend> and yes, don't use picocontainer[16:14:06] <reverend> use spring or guice[16:14:33] *** cvasilak has quit IRC[16:14:36] <cheeser> "i'm going to sail across the ocean. i think i'll use a sextant."[16:14:38] <cheeser> 8^)=[16:14:41] <JanK> cheeser: found it, its this.A.value ;)[16:14:52] <cheeser> uh...[16:15:15] <cheeser> pastebin that code?[16:15:36] <magmarules> cheeser: im not planning on using any framework atm, i was just going to implement DAOs and was very unhappy whit needing to hardcode constructor DAO methods in a factory[16:16:35] *** COM-S|Hokar has joined ##java[16:17:23] <JanK> cheeser: actually A.this.value, but here it is: http://pastie.textmate.org/private/inaiurqlfgs994kkyaiaw[16:19:27] <waz> frameworks are quite useful[16:19:40] <fr0ggler> i use Spring - it's awesome[16:19:58] <fr0ggler> not to say what's right for me is for you, but there we go[16:20:15] <waz> why Spring over Guice?[16:20:25] *** CapriCoRN^80 has joined ##java[16:20:49] <CapriCoRN^80> can anyone tell me how can i do the reverse engineering of my java classes to UML in ArgoUML ?[16:21:46] <marvi> waz: depends on you needs, very different animals.[16:22:00] <waz> marvi: I know[16:22:14] <waz> but we were talking DI specifically[16:22:24] <waz> and they are not very different in that respect[16:22:38] <cheeser> JanK: ok. that makes sense.[16:22:59] <marvi> waz: DI is used in a context, if it is a real world project. Context matters.[16:23:40] <waz> are you always an ass?[16:23:54] <waz> or is it just dense?[16:23:57] *** scott_w has joined ##java[16:24:01] *** codethief has joined ##java[16:24:51] *** phenom9600 has quit IRC[16:25:28] <magmarules> just to clarify, the correct way to access for example, Students from a ClassDAO is to do it through StudentDAO right ?[16:25:32] *** Teckla has joined ##java[16:25:54] <BeholdMyGlory> do you have to install Qt Jambi on every computer that wants to run Qt Jambi applications? is there any good way to ship Qt Jambi with the program?[16:26:06] *** thpar has quit IRC[16:26:19] *** ChanServ sets mode: +o waz[16:27:53] *** Veritto has joined ##java[16:28:14] <cheeser> BeholdMyGlory: you can't run a java problem with its dependent libraries[16:28:31] <Veritto> HI[16:28:55] <Veritto> How Can I repaint from Panel?[16:29:05] <cheeser> ~javadoc Panel[16:29:07] <Woot4Moo> cheeser[16:29:08] <javabot> cheeser: http://is.gd/kYdT [org.apache.wicket.markup.html.panel.Panel]; http://is.gd/kYdU [java.awt.Panel][16:29:10] <Woot4Moo> i think you can[16:29:20] <cheeser> Woot4Moo: think what you like.[16:29:20] <Woot4Moo> run a program with dependent libraries[16:29:30] <Veritto> I use repaint but it doesn't show the change[16:29:35] <Woot4Moo> ive seen it done off the command line using hibernate libraries[16:29:44] <cheeser> Veritto: invalidate your layout[16:29:48] <cheeser> Woot4Moo: no you haven't.[16:30:05] <Woot4Moo> then the person was lying to me :([16:30:05] <Veritto> how?[16:30:11] <cheeser> or full of shit[16:30:14] <waz> or cheeser is![16:30:34] *** Iowahc has joined ##java[16:30:40] <cheeser> it's a real mystery. whom to believe?[16:30:45] <Iowahc> I need a JoptionPane with checkboxes to choose and as return of this Dialog the Array of selected Objects[16:30:45] <Iowahc> how to do?[16:30:45] <cheeser> i want to believe![16:30:59] <cheeser> ~~ Iowahc javadoc JDialog[16:30:59] <javabot> Iowahc: http://is.gd/kYeH [javax.swing.JDialog][16:31:15] <waz> why be so dogmatic? I believe both of you[16:31:24] <magmarules> unn pico seemed nicer, clear syntax and didnt require the @inject and bind stuff =/ what will be the advantages of guice vs pico ? =)[16:31:26] <waz> being the fair and open minded person that I am[16:31:29] *** Frostshock has quit IRC[16:32:03] <reverend> magmarules: they're actually used by real people in real environments and aren't someone's random experimentation[16:32:28] <magmarules> reverend: ok =)[16:32:40] <waz> is pico still in active development?[16:32:51] <cheeser> the editor is i'm sure.[16:32:52] <cheeser> 8^)=[16:33:03] *** jbwiv has joined ##java[16:33:12] *** seejay has joined ##java[16:33:13] <waz> haha[16:35:29] *** maio has joined ##java[16:35:38] *** Iowahc has left ##java[16:35:45] <maio> hi. how should I convert byte[] to String?[16:37:24] *** Sulis has joined ##java[16:37:39] <cheeser> ~~ maio type conversion[16:37:40] <javabot> When trying to convert from one type to another, you should start by checking the docs for the two endpoints. If an endpoint (or both) is a primitive, you'll have to look at the wrapper class's docs.[16:38:04] *** ldam has quit IRC[16:38:04] *** acuster has quit IRC[16:39:45] * Logi is on the road again[16:39:51] <maio> uhm? :)[16:39:53] * Logi is also typing into the wrong window[16:40:13] *** Sonderblade has quit IRC[16:40:19] <magmarules> cheeser: how would you inject a Hibernate session in the dependencies ? I dont want him to create a new Session i want him to call HibernateUtil.getSession .[16:40:44] <maio> I encrypted something (data.getBytes()) using RSA but decrypt returns byte[] and I don't know how to convert it to String[16:40:50] <cheeser> i'd use spring's transaction support[16:40:56] <cheeser> ~~ maio type conversion[16:40:56] <javabot> When trying to convert from one type to another, you should start by checking the docs for the two endpoints. If an endpoint (or both) is a primitive, you'll have to look at the wrapper class's docs.[16:41:20] <magmarules> cheeser: ohh ok =)[16:41:30] <maio> ok 1. what's endpoint?[16:41:37] <maio> 2. wrapper?[16:42:07] <Aquanox> maio -> new String(byte[]);[16:42:07] <Woot4Moo> oh boy[16:42:18] <cheeser> ~smack Aquanox[16:42:18] * javabot smacks Aquanox in the mouth[16:42:19] <Woot4Moo> java 5 thankfully takes care of Autoboxing[16:42:26] <cheeser> ~~ Aquanox spoonfeeding[16:42:26] <javabot> Spoonfeed a newbie for a day and he'll come back with more questions. Teach him to find his own answers and you'll both be better off: you won't get stuck answering the easy questions and he'll be much more productive than before.[16:43:44] <maio> Aquanox: thank you[16:44:07] <cheeser> maio: if you're trying to create something, you should start by reading the docs for that something.[16:44:12] <cheeser> that's just basic common sense.[16:45:07] <gabbah> how can i program a java program? like photoshop?[16:45:13] <gabbah> :P[16:45:34] <Veritto> cheeser, I have invalidate the Panel, myPanel.setLayout(null);[16:45:55] <cheeser> that's not invalidating the layout. that's nulling it.[16:46:01] *** StanAccy has joined ##java[16:46:14] <Veritto> and how do it?[16:46:18] <Aquanox> cheeser -> ok[16:46:26] *** sanity has quit IRC[16:46:58] <cheeser> Veritto: look in the javadoc for something involving the word invalidate[16:47:09] *** AMcBain has joined ##java[16:48:25] *** CapriCoRN^80 has quit IRC[16:50:55] *** mazzachre has quit IRC[16:51:14] *** eventualbuddha has joined ##java[16:52:22] <eventualbuddha> totally newbie easy question: how do I bundle an application that runs under jetty into a JAR such that I can run it by doing "java -jar myapp.jar" (or close enough)?[16:53:21] <cheeser> ~~ eventualbuddha manifest[16:53:22] <javabot> Manifests are a way of specifying metadata about a jar file inside the jarfile. See http://java.sun.com/javase/6/docs/technotes/guides/jar/jar.html#Manifest%20Specification[16:53:44] <fr0ggler> ~~ eventualbuddha ant[16:53:45] <javabot> eventualbuddha, ant is a tool for building Java programs, found at http://ant.apache.org[16:53:56] <fr0ggler> just as one example[16:54:00] <eventualbuddha> if it helps, the project is already under maven[16:54:08] <fr0ggler> eventualbuddha, ah easy then[16:54:08] <eventualbuddha> and I use "mvn jetty:run" to start it[16:54:13] <maio> cheeser: well I tried .toString() but it throw something completly different at me so I came here to get some help :)[16:54:48] <cheeser> learn to use the API[16:54:59] <fr0ggler> eventualbuddha, you want to look up maven-compiler-plugin[16:55:10] <Woot4Moo> maio do you know what .toString() does?[16:55:27] <eventualbuddha> fr0ggler: cool, thanks[16:55:42] *** benny269 has joined ##java[16:55:43] *** whaley has joined ##java[16:55:47] <benny269> hey all, im looking for code to find the intersection of 2 line segments. Can anyone help or redirect to another person/channel/book/website?[16:56:02] <maio> Woot4Moo: well from it's name I would guess that it should return string representation of that object[16:56:11] <Woot4Moo> no[16:56:17] <Woot4Moo> it returns the location in memory[16:56:23] <cheeser> wrong![16:56:26] <Woot4Moo> as a developer you are supposed to override it[16:56:27] <Woot4Moo> yes![16:56:34] <Woot4Moo> it returns a hex value[16:56:38] <maio> Woot4Moo: great name for such functionality :)[16:56:39] *** MigoMipo has joined ##java[16:56:49] <Woot4Moo> you also said you cant bundle dependent libraries with a java app[16:56:53] <Woot4Moo> <3[16:56:55] <cheeser> it returns the string representation of the object. the implementatin on Object returns the reference value[16:57:02] <cheeser> Woot4Moo: no, i did not.[16:57:07] <Woot4Moo> umm yes?[16:57:15] <cheeser> i said you can't run java problems without their dependendent libs.[16:57:46] <benny269> any help?[16:57:57] <Woot4Moo> sigh i need to break out some reading glasses[16:58:01] <cheeser> ~~ benny269 google java line intersection[16:58:01] <javabot> http://letmegooglethatforyou.com/?q=java+line+intersection[16:58:30] <reverend> actually, to be fair, cheeser fat fingered that line[16:58:39] <cheeser> which one, reverend ?[16:58:50] <Woot4Moo> maio i recommend reading the following 2 books as you clearly have little exp with java: HeadFirst Java and Effective Java 2nd edition[16:58:59] *** ffgeek200 has joined ##java[16:59:06] <reverend> cheeser: the one you just referred to[16:59:10] <reverend> you actually said the opposite[16:59:31] <reverend> 11:30 <@cheeser> BeholdMyGlory: you can't run a java problem with its dependent libraries[16:59:32] <Woot4Moo> cheeser i do love you but: <@cheeser> BeholdMyGlory: you can't run a java problem with its dependent libraries[16:59:57] <reverend> but i just figured people understood at the time[17:00:13] <cheeser> i said "problem" instead of program. big whoop![17:00:13] <cheeser> 8^)=[17:00:27] <reverend> and 'with' instead of 'without'[17:00:28] <fr0ggler> and you said with :D[17:00:29] *** Resistance has quit IRC[17:00:35] <fr0ggler> *bad cheeser* :D[17:00:39] <cheeser> ah! i did miss that.[17:00:39] <cheeser> 8^)=[17:00:57] <maio> Woot4Moo: this was my last line of java code (hopefuly) :) (I had to wrap RSA encryption/decryption so I could use it in PL/SQL)[17:01:00] <benny269> i've been through those links and the sweep line method is beyond my ability and need to use a concise algorithm ideally using intersectsLine from the Class Line2D. If there's a prticular website you can recommend...[17:01:52] <maio> Woot4Moo: if I had to write more Java code I would read some books/APIs for sure[17:02:00] <reverend> benny269: have you considered that if it was possible to do it in a way you understand, that'd be the most popular hit on google?[17:02:50] *** gdoko has quit IRC[17:03:22] <gabbah> so, why can't a switch statement take a long value?[17:03:26] *** xabbuh has quit IRC[17:03:36] <cheeser> gabbah: one of many reasons not to use switch[17:03:48] <gabbah> many reasons?[17:03:58] <gabbah> i never heard that before.. why do u say that?[17:04:25] *** staar2 has quit IRC[17:04:41] <gabbah> what's so bad about switch statements?[17:04:44] <waz> ~u[17:04:57] * cheeser kicks the bot[17:04:58] <CandleCandle> why would webstart give me a MissingFieldException (http://pastebin.com/d6ddb3a0b) when the jnlp has a '<application-desc main-class="com..."/>' as a member of the <jnlp> container?[17:05:01] <cheeser> ~ping[17:05:02] <javabot> http://www.nataliedee.com/071405/ping.jpg[17:05:05] <cheeser> ~u[17:05:07] <cheeser> ~info u[17:05:07] <javabot> u was added by: ricky_clarkson on 11-27-2005 at 6:48 AM, EST and has a literal value of: <reply>U is Dutch for "you" or an aolbonic meaning "I am stupid".[17:05:14] <cheeser> hrm.[17:05:33] * waz kicks javabot[17:05:43] <waz> javabot: u[17:05:43] <cheeser> i wonder if reply is broken.[17:05:51] <AMcBain> yeah, those have been broken for a while (single letter factoids)[17:05:57] <cheeser> or maybe it's the one letter factoid problem.[17:06:01] * fr0ggler pats javabot affectionately. Then kicks javabot.[17:06:18] *** Veritto has quit IRC[17:06:24] <gabbah> cheeser?[17:06:29] <cheeser> gabbah![17:06:55] <gabbah> cheeser, i didn't see a reply to my question?[17:07:03] <gabbah> maybe u missed it?[17:07:16] <AMcBain> you*[17:07:24] <gabbah> yeah :)[17:07:41] *** lhunath has joined ##java[17:07:42] <gabbah> thank u AMcBain ;)[17:07:46] <eventualbuddha> hmm. this is not turning out to be as easy as I thought[17:07:59] <cheeser> ~~ gabbah aolbonics[17:07:59] <javabot> gabbah, aolbonics is using unnecessary abbreviations such as 'u', 'r', 'ur', 'thx', etc. Using this language depicts you as an imbecile in the eyes of the helpful regulars in this channel, and is generally not tolerated. If you want intelligent answers, the least you can do is speak intelligently. Additionally arguing about this rule will get you nowhere except banned. Have a nice day![17:08:30] <lhunath> at which points is an @PostConstruct annotated method on a Stateful bean executed?[17:08:31] * AMcBain likes English, but hates internet speak.[17:08:58] <gabbah> well it's lazy speak really isn't it? i can agree it looks a bit dumb sometimes though[17:08:59] *** Niike has joined ##java[17:09:07] <cheeser> sometimes?[17:09:08] <cheeser> 8^)=[17:09:27] <gabbah> but smilies are part of internet speak as well though[17:09:54] <AMcBain> gabbah: I try to avoid over using them. every sentence shouldn't be postfixed with a ":P"[17:10:00] <cheeser> lots of things are, gabbah[17:10:03] <AMcBain> for example[17:10:21] <fr0ggler> yeah but they convey an emotion, which would otherwise be almost impossible to contextualise in the typed word[17:10:42] <fr0ggler> however that's not to say they should be misused #8-) *slaps self*[17:10:43] <AMcBain> what? sticking your tongue out after every sentence?[17:10:58] <AMcBain> /jk[17:11:00] <gabbah> i guess for you americans, it looks as bad as when swedish people write a word as two separate words that SHOULD be written as ONE word. In swedish, we don't separate words like in english.[17:11:12] *** TooAngel has joined ##java[17:11:17] *** litb has joined ##java[17:11:20] <litb> hello all[17:11:27] <AMcBain> I don't really mind that kinda stuff unless it makes it unreadable.[17:11:32] <litb> why is List<String>[] a = new List<?>[3]; allowed?[17:11:34] <waz> dumb swedes[17:11:40] <gabbah> no, you should write "I'm smiling now" :P[17:11:42] *** TooAngel has left ##java[17:11:50] <CandleCandle> Not all of us are American, thanks.[17:11:54] <AMcBain> litb: you forgot the () after the <?>[17:11:58] <AMcBain> I think[17:12:03] <lhunath> Hmm; let me get this straight. If I have a stateful bean; and I do one call to it after getting a reference to it via JNDI. Then, later, I do another call on it getting its reference from JNDI again; am I talking to the same stateful bean?[17:12:08] <litb> the ibm doc says it that way[17:12:17] <litb> i wonder why it is allowed[17:12:19] <fr0ggler> CandleCandle, likewise! Not just American people speak English you know[17:12:23] <AMcBain> litb: well, Generics and arrays don't mix well.[17:12:28] <litb> couldn't that be used to subvert type safety?[17:12:34] *** bhz- has quit IRC[17:12:58] <AMcBain> people can do anything given enough time and motivation ...[17:12:58] <litb> beause a List<?>[] could contain elements of types that are super classes of String ?[17:13:09] <litb> i mean List of elements of types that...[17:13:44] *** casmo has joined ##java[17:14:02] <litb> hmm strange, it doesn't work. ibm doc says it would oO[17:14:13] <AMcBain> generics works on type erasure ... so it is possible to do stuff that might not otherwise be possible if it didn't lose that information, if you do something sufficiently tricky to avoid detection by the compiler.[17:14:23] <AMcBain> (someone posted a case a while back)[17:15:12] <litb> oh wait[17:15:15] <litb> i read it wrong[17:15:36] <litb> it just says new List<String>[3] is illegal and new List<?>[3] is legal. and it is i tested :D[17:15:50] *** ishi has left ##java[17:15:56] <litb> java generics suck big times :/ so complicated[17:15:59] <AMcBain> generics are a strange beast[17:16:05] <AMcBain> s/are/is/[17:16:12] *** dos000 has joined ##java[17:16:32] *** ldam has joined ##java[17:16:41] <dos000> anyone has experience to share as to the max keys one can select (with the java nio selector) on different platforms ?[17:16:50] <litb> let's hope java7 will get real non-erased generics :/[17:17:28] <AMcBain> One thing I notice (just an observation, those more advanced in generics can have their say) is that you can do <MyClass> or <? extends MyClass> but you can't have a type that says "I can store both MyClass *and* subclasses of MyClass" ... which works if you assume MyClass is an interface or abstract ...[17:17:28] *** dpy has quit IRC[17:17:32] <fr0ggler> litb: generics are great, but yeah, they can get a bit complicated[17:18:27] <gabbah> litb, i just get Cannot create a generic array of List<String> when i do List<String>[] a = new List<String>[3];[17:18:34] <AMcBain> Now, I haven't really run into a case where I want to store both those things in the same Collection yet (except in playing around, or going down a wrong design choice) but still, think it should be possible.[17:18:58] <AMcBain> gabbah: Arrays and Generics don't mix well. It goes both ways.[17:19:47] <gabbah> luckily, they don't seem to ask about that on SCJP.. phew[17:20:16] * AMcBain doesn't see the point in being certified in something he can definitely prove his competence in without such a document.[17:20:23] *** popcornPanic has quit IRC[17:20:35] <gabbah> well, i can't :D[17:20:46] <gabbah> i need that document! :D[17:21:05] <cheeser> student?[17:21:15] *** jchauncey has joined ##java[17:21:19] <AMcBain> Certification (for IT/CS/IS) is like saying "I spent all my time learning little silly nuances of this instead of gaining real experience ... please scrutinze me!"[17:21:26] <gabbah> AMcBain, but you CAN store MyClass and subclasses of it, so what were you asking about?[17:21:29] <reverend> gabbah: just as an FYI, lots of companies actually consider certifications a negative on resumes[17:21:38] <cheeser> AMcBain: your teeth a crooked and that hair style it ludicrous.[17:21:45] <cheeser> oh, i see. nevermind. P^)=[17:22:02] <gabbah> haha, a negative? i don't think so.. i mean come on[17:22:09] <reverend> yes.[17:22:19] <AMcBain> gabbah: no, you can't ... ? extends That means they can only be a class implementing That or a subclass of That as the case may be.[17:22:39] *** rlubke has joined ##java[17:22:43] <AMcBain> If I just say That, it literally means I can only store That.[17:22:46] <reverend> it means 'i either don't care enough about software development or am not creative enough to contribute to relevant sources of experience'[17:22:58] <jchauncey> morning guys[17:22:59] <AMcBain> hehe[17:23:14] <gabbah> AMcBain, you said STORE. so i thought you meant store in ArrayList<MyClass>. and you can store sublcasses there right[17:23:29] <AMcBain> let me write a test case[17:23:40] <reverend> people who are good at writing software.. write software, whether they get paid for it or not, and hence, people who are good at writing softare can show you software they've written[17:23:48] * AMcBain has found that his side projects and other things he works on to build a simple portfolio is quite impressive to companies ... they actually do check out your website :)[17:23:49] *** maio has left ##java[17:24:02] *** dnmo has quit IRC[17:24:27] <AMcBain> Stands me out over my classmates ... kinda sad they don't try different/various things, but that's their loss.[17:24:27] <gabbah> List<MyClass> means that reference can point to only A = ArrayList<MyClass>, but A can store subclasses of MyClass. that's what i meant[17:24:49] <reverend> people who are going to be clockwatchers, nine to fivers, non-starters, usually write certs[17:24:55] *** BlindHunter has joined ##java[17:25:08] <Woot4Moo> where is there a 9-5 programming job?[17:25:13] <reverend> because it's the easy way out and doesn't actually require them to learn how to write software[17:25:43] <reverend> Woot4Moo: look in big, soulless, boring companies that promote based on seniority[17:25:44] <gabbah> well. SCJP may not require it.. but higher certs i think will require you to put in the coding time as well[17:25:56] <jchauncey> when you say certs though are you grouping that with actual degrees?[17:26:04] <Woot4Moo> no[17:26:08] <Woot4Moo> how could you?[17:26:08] <gabbah> i mean sun certs[17:26:14] <reverend> gabbah: there are no certs in the java track that require you to do anything but memorize stuff[17:26:35] <gabbah> i think u need to understand as well[17:26:36] <Woot4Moo> scjp had a bit of programming on it, in fact when i took it it was all java.sql shit[17:26:38] <jchauncey> dosnt europe call their "degrees" certs?[17:26:41] <jchauncey> thats why i was asking[17:26:52] <gabbah> not that i know[17:26:55] <gabbah> cert[17:26:59] <Woot4Moo> well in europe land when someone comes over i think that the university part gives it away[17:27:17] *** popcornPanic has joined ##java[17:27:26] <reverend> jchauncey: some universities issue 'university certificates' which are basically 2 year degrees[17:27:31] *** Sagi22 has joined ##java[17:27:33] <reverend> i think they call them associates degrees in USA[17:27:44] <jchauncey> yeah[17:27:54] <gabbah> well that's another thing[17:28:03] <gabbah> thats actual education[17:28:10] <gabbah> of course, that's a degree, not a cert[17:28:30] <reverend> yeah, and most comp. sci degree holders aren't very good at writing software either (at least initially)[17:28:40] <Woot4Moo> <--[17:28:49] <gabbah> true. because they had to study tons of other shit[17:29:03] *** tds5016 has joined ##java[17:29:09] <jchauncey> i didnt write any code after my 2nd year of college[17:29:13] <jchauncey> it was all theory[17:29:22] <gabbah> yeah exactly[17:29:26] <gabbah> that's what i'm saying[17:29:27] <tds5016> hello all. can someone tell me why Date date = new Date(); gives me an error?[17:29:27] <AMcBain> well, a well rounded CS degree won't plop you in front of one language and say "here" and do that for 4 years, and it won't be 100% theoritcal either.[17:29:32] <jchauncey> pdas, ndfsa, etc...[17:29:34] <cheeser> tds5016: import the date[17:29:36] <tds5016> it's telling me it can't instantiate.[17:29:37] <Woot4Moo> try importing it tds[17:29:44] <cheeser> "duh"[17:29:47] <tds5016> cheeser: how do I do that?[17:29:48] <tds5016> sorry.[17:29:52] <cheeser> ~~ tds5016 imports[17:29:52] <javabot> tds5016, import is http://java.sun.com/docs/books/tutorial/java/interpack/usepkgs.html[17:29:58] <tds5016> thanks cheeser[17:30:28] <jchauncey> anyone here know what has to be in the jboss.xml file if you have no datasources or external dependencies? basically i need an empty descriptor[17:30:37] <reverend> gabbah: speaking as someone who reviews a lot of resumes and occasionally hires people, just be aware that if i see two resumes, both with no professional experience, but one has a cert and the other has his own software or has contributed to a free project, the cert guy goes in the garbage[17:30:37] <tds5016> sorry, I meant WHAT do import?[17:30:45] <reverend> i don't even save those resumes[17:30:48] <tds5016> it's been along day. haha.[17:31:08] <Woot4Moo> import java.util.*;[17:31:12] <gabbah> reverend, yeah, but what if none of them have any code to show you?[17:31:14] <Woot4Moo> or to be correct import java.util.Date;[17:31:33] <reverend> gabbah: then they're probably worthless to me[17:31:46] <gabbah> reverend, or maybe that guy wrote tons of code, but it's all spaghetti code[17:31:46] <cheeser> reverend: yep[17:31:56] *** JanK has quit IRC[17:32:03] <tds5016> oh snap... eclipse imported the wrong one.[17:32:10] <cheeser> ~eclipse--[17:32:10] <javabot> eclipse has a karma level of -72, cheeser[17:32:12] <tds5016> sorry cheeser. you're use of eclipse strikes again. haha[17:32:12] <reverend> gabbah: if they did that, they will have gotten one step closer to a job than the cert guy[17:32:12] <Woot4Moo> the sql one?[17:32:18] <reverend> because i'll review their code[17:32:43] <gabbah> reverend, he might know how to write a fancy program, but uses very poor design, doesn't comment his code, uses bad variable names and so on...[17:32:44] *** eduardopl has joined ##java[17:32:55] <reverend> yes, and?[17:32:58] <AMcBain> gabbah: you won't win[17:33:03] <cheeser> gabbah: and i'd want to hire him why?'[17:33:04] <gabbah> haha[17:33:18] *** deSilva has quit IRC[17:33:49] <reverend> the point is that th cert guy goes in the garbage immediately. the spaghetti coder interests me eough to review their code and (possibly) then throw their resume in the garbage[17:33:52] <gabbah> i just think you need to look at what the guy has actually coded and the quality of it. a cert is not that easy to get after all[17:34:00] <tds5016> next question: why does int seconds = date.getSeconds(); give me a warning?[17:34:06] <reverend> gabbah: of course i look at that[17:34:08] <tds5016> and strike through the method?[17:34:14] <Woot4Moo> deprecation possibly?[17:34:19] <Woot4Moo> what does the yellow wavy line say[17:34:25] <Woot4Moo> oh yeah its deprecated[17:34:27] <reverend> do you think i just see 'contributed to XXX project' on the resume and write them an offer?[17:34:37] <cheeser> tds5016: try reading the fucking warning![17:34:41] <gabbah> well, i don't know how it is in other countries... but here, working as a consultant, a cert makes it easier to "sell me"[17:34:43] <cheeser> damn newbies and their IDEs[17:34:52] <tds5016> oh... deprecated. sorry.... I read the wrong thing before.[17:34:53] <tds5016> sorry.[17:35:04] <Woot4Moo> cheeser is raged[17:35:06] <Woot4Moo> :)[17:35:16] <gabbah> yellow line means "warning"[17:35:48] <tds5016> yeah, that was dumb on my part.[17:35:49] <gabbah> or "really? are you sure?"[17:35:52] <cheeser> Woot4Moo: tds5016 is a complete, ignorant newbie who refuses to take the time to learn anything.[17:36:15] *** The_Birdman has joined ##java[17:36:25] <Woot4Moo> cheeser: future coworker for one of us[17:36:26] *** casmo has quit IRC[17:36:29] <tds5016> cheeser does have every right to be pissed at me for that one.... that was a stupid mistake on my part to say the least.[17:36:34] <cheeser> Woot4Moo: not me[17:36:39] <gabbah> reverend will hire him in the future :)[17:36:41] <The_Birdman> Hello guys. What would be the best strategy to maximize cpu usage?[17:36:59] <AMcBain> BOINC?[17:37:00] *** LordMetroid has quit IRC[17:37:04] <cheeser> The_Birdman: a really tight while loop[17:37:44] <The_Birdman> cheeser: I am trying to optimize a threadpoolexecutor among other things. The application is memory hungry but cpu usage is always low[17:37:55] <waz> The_Birdman: on a pc? Run Vista[17:37:58] <waz> with 1 gig ram[17:38:00] <AMcBain> haha[17:38:01] <tds5016> okay, how do I get the hour minute, day of month, etc from the date class? or is there another class I should be using?[17:38:02] <cheeser> increase the memory to the VM then[17:38:04] <The_Birdman> embedded linux, 2gb of ram[17:38:08] <cheeser> or optimize your memory usage[17:38:18] <The_Birdman> it's a huge j2ee app on jboss[17:38:35] *** vix85 has quit IRC[17:38:54] <The_Birdman> I already did lots of profiling for the last 2 weeks and I am optimizing thread pools executors right now[17:39:18] <tds5016> and btw cheeser, I am sorry about that.[17:39:20] *** bhz- has joined ##java[17:39:30] <cheeser> 8^)=[17:39:51] <tds5016> nevermind, Calendar object replaced it...[17:40:02] <tds5016> sometimes documentation does help.... sometimes I hate me. haha.[17:41:33] *** UT2K3 has joined ##java[17:42:28] *** amitev has quit IRC[17:42:58] * cheeser watches tds5016 learn the hard way[17:45:09] *** goki-_- has joined ##java[17:45:43] *** veleno has quit IRC[17:46:14] *** EdwardIII has quit IRC[17:50:10] *** Hink has joined ##java[17:51:46] <jchauncey> anyone know anyything about this jboss error - DEPLOYMENTS MISSING DEPLOYERS: Name[17:52:14] *** thecarlhall has joined ##java[17:52:35] <dmlloyd> your deployment is missing a deployer[17:52:53] <fr0ggler> dmlloyd, nothing gets past you :D[17:52:54] *** acuster has joined ##java[17:52:54] <dmlloyd> also there's probably several more lines of error that you've left off[17:53:05] <dmlloyd> you should pastebin it[17:53:46] *** TranceControl has quit IRC[17:53:58] *** morkar- has quit IRC[17:54:37] <eduardopl> can somebody help me out with an english translation? not java related[17:54:48] <eduardopl> actually, java related[17:54:52] <eduardopl> but not code[17:56:27] <jchauncey> ~pastebin[17:56:27] <javabot> http://eugeneciurana.com/pastebin Paste the final url after you've pasted your stuff there.[17:56:33] *** UT2K3 has quit IRC[17:57:13] <eduardopl> http://pastebin.com/m5f0c5842[17:57:29] <eduardopl> i'd like to know if there are any grammar errors in there[17:59:20] *** jbwiv has quit IRC[17:59:41] *** teralaser has quit IRC[17:59:48] <eduardopl> i gtg now[17:59:50] *** eduardopl has quit IRC[18:00:10] <marvi> That was odd.[18:00:15] <waz> wonder if uses gtg in his document![18:00:49] <fr0ggler> didnt wait long did he[18:01:55] <waz> weird[18:01:55] <waz> <ritterjako> can you help me with a english quiz become i m germany and my english is not so great[18:01:57] <marvi> fr0ggler: he didn't want us to waste his valuable time.[18:02:12] <pr3d4t0r> I can has.[18:02:13] <pr3d4t0r> :)[18:03:41] <fr0ggler> can u check out not java related java not code grammar. No? ok bye thx *confused*[18:03:49] *** ChanServ sets mode: +o pr3d4t0r[18:03:51] *** fr0ggler was kicked by pr3d4t0r (pr3d4t0r)[18:03:57] *** ChanServ sets mode: -o pr3d4t0r[18:04:05] *** fr0ggler has joined ##java[18:04:10] * pr3d4t0r eyes fr0ggler.[18:04:12] <fr0ggler> hey i was joking![18:04:13] * pr3d4t0r hugs fr0ggler.[18:04:22] <pr3d4t0r> fr0ggler: So was I -- it was just a /kick :*[18:04:28] * fr0ggler cries *snif*[18:04:30] *** seejay has quit IRC[18:04:31] <tds5016> how do I get the retun from runtime.exec()? .toString isn't working.[18:04:33] <pr3d4t0r> fr0ggler: And you misspelled grammer.[18:04:39] <tds5016> it returns an outputStream as I'ms ure you know.[18:04:55] <pr3d4t0r> tds5016: No, it returns a Process.[18:05:08] <tds5016> sorry.... I said the wrong thing.[18:05:15] <fr0ggler> tds5016, i thought exec returned a Process[18:05:21] <tds5016> I meant process.getOutputStream();[18:05:38] *** foenichs has joined ##java[18:05:51] <pr3d4t0r> tds5016: Since you have the output stream, just read from it. Use a reader or whatever.[18:05:59] <marvi> tds5016: http://java.sun.com/docs/books/tutorial/essential/io/[18:06:07] <cheeser> ~smack tds5016[18:06:07] * javabot smacks tds5016 in the mouth[18:06:09] <tds5016> thanks.[18:07:30] *** foenichs has quit IRC[18:07:53] <fr0ggler> don't you read Process output by using process.getInputStream()?[18:07:59] <fr0ggler> its a bit counter-intuitive[18:08:28] *** jbwiv has joined ##java[18:09:34] <cheeser> not really. you're reading *in* to the VM[18:10:05] *** Dr_Link has joined ##java[18:10:18] *** developerhealey has left ##java[18:10:22] <fr0ggler> cheeser, yeah I guess - i got a bit confused over it a couple of times in the past[18:10:26] <fr0ggler> maybe that's just me :)[18:11:57] *** elindio has joined ##java[18:12:46] *** ffgeek200 has quit IRC[18:13:07] *** ffgeek200 has joined ##java[18:13:30] *** spathi has joined ##java[18:15:53] *** ThFabba has quit IRC[18:18:38] *** Goundy has joined ##java[18:19:24] <goki-_-> So what's happening with Java 7 properties stuff?[18:19:25] *** Craghag has joined ##java[18:19:26] *** dnmo has joined ##java[18:20:14] *** selckin has joined ##java[18:21:02] *** Varox has quit IRC[18:22:05] *** deepjoy has quit IRC[18:22:10] *** amnesiac has joined ##java[18:23:44] <fr0ggler> laters all![18:23:46] *** fr0ggler has quit IRC[18:24:33] <Craghag> can I do an application which (if is running in a directory L://blabla/lalala) prints in anywhere: "I'm being executed from L://blabla/lalala" ??[18:25:57] *** Varox has joined ##java[18:26:15] <Woot4Moo> yes[18:27:27] <Woot4Moo> craghag[18:27:49] <Craghag> Woot4Moo: how can I do it, plz?[18:27:51] <sproingie> i'm curious how you do that in java as well[18:28:28] <Woot4Moo> one sec[18:28:34] <Woot4Moo> as it would seem like thats an api function[18:28:36] <Woot4Moo> of System[18:28:43] <Woot4Moo> or perhaps File[18:28:59] *** cyth has joined ##java[18:29:04] <Woot4Moo> wherein you get the current directory[18:29:06] *** cyth has quit IRC[18:29:08] <waz> ~System[18:29:08] <javabot> waz, I have no idea what System is.[18:29:11] <sproingie> that's user.dir[18:29:19] <waz> ~javadoc System[18:29:21] <javabot> waz: http://is.gd/iN33 [java.lang.System][18:29:27] *** cyth has joined ##java[18:29:31] *** notcyth has joined ##java[18:29:35] <Woot4Moo> thats what hes asking for[18:29:42] <Woot4Moo> sproingie[18:29:58] <goki-_-> user.dir and user.home are really easy to get confused :)[18:30:00] <Woot4Moo> what directory is my .exe file inside of[18:30:04] <sproingie> System.getProperty('user.dir') ... is that necessarily going to be dirname(argv[0]) in the C sense?[18:30:05] *** notcyth is now known as cyth[18:30:16] <waz> your exe?[18:30:26] <Craghag> System.getProperty("user.dir") gives the directory which the application is running or the home?[18:30:28] <Woot4Moo> waz it was in reference to crags question[18:30:30] <sproingie> not that the location of the main class is all that interesting[18:30:39] *** casmo has joined ##java[18:30:56] <waz> he didn't mention exe's[18:31:11] <Woot4Moo> ok his question was how can i display where my program is being executed from[18:31:13] *** pandora-- has joined ##java[18:31:16] *** RLa has joined ##java[18:31:21] <Craghag> yeah[18:31:34] <Craghag> it's just what i was looking for, sorry for the english[18:31:37] <sproingie> that could be interpreted a couple ways. yay ambiguity[18:31:37] <Woot4Moo> one would argue that you can just pick whereever the .exe file is saved and prepend it with the drive location[18:32:23] *** Mortomes has joined ##java[18:32:35] <sproingie> javac doesn't compile to .exe, so if you want to know where the .exe lives that's being executed, you'd use dirname(argv[0]) or whatever the windows equivalent thereof is[18:32:41] <Craghag> I need to display where my program is being executed from[18:33:02] *** tds5016 has left ##java[18:33:06] *** Frostix has quit IRC[18:33:23] <Craghag> I'm using linux[18:33:27] <_W_> Craghag, which program would that be, java?[18:33:44] *** pirx_ has quit IRC[18:33:46] <Woot4Moo> i had this assignment my first year of college[18:33:49] <_W_> also, what do you mean "executed from"?[18:33:50] *** shervin_a has quit IRC[18:34:00] <Woot4Moo> its all built in api functionality[18:34:05] <Woot4Moo> google is your friend[18:34:11] <Craghag> _W_: Java[18:34:12] <gabbah> probably he's asking for the directory where the class file with the main method is located[18:34:24] <_W_> Craghag, "which java" in your shell[18:34:26] *** Varox has quit IRC[18:34:59] <_W_> and that might be located anywhere in the classpath[18:35:20] <gabbah> i think he meant his own java program[18:35:29] <_W_> (though you can find out the location from the class (get its protection domain and the code source from that)[18:35:43] <sproingie> i have no idea now. *shrug*[18:35:58] <_W_> Craghag, more importantly is, why do you want to find this out?[18:36:05] <Craghag> :S sorry, but what I'm trying to say is: If I have an application running at H://blablabla the application says: "I'm running from H://blablalba"[18:36:05] <_W_> what's the real problem you want to solve?[18:36:22] <_W_> Craghag, applications don't "run from" a specific location[18:36:31] <Craghag> mmm[18:36:33] <Craghag> :S[18:36:37] *** Goundy has quit IRC[18:36:42] <_W_> some operating systems have the concept of a "current working directory"[18:36:43] <Woot4Moo> crag[18:36:44] <Woot4Moo> http://www.rgagnon.com/javadetails/java-0076.html[18:37:07] <Woot4Moo> for the love of christ if i ever have to work with you im going to kill myself[18:37:07] <_W_> but java programs consist of multiple classes, which may come from multiple locations[18:37:26] *** convivial has joined ##java[18:37:47] <Craghag> I'm trying to understand better JWS... this kind of application maybe would help me[18:37:47] *** convivial has joined ##java[18:37:54] <sproingie> JWS ... web server?[18:37:56] <waz> operating systems have a concept of current working directory?[18:38:00] <waz> shells do[18:38:01] <gabbah> what if you open a file, giving only the file name? there must be a working direcory, right?[18:38:01] <Craghag> java web start[18:38:06] <sproingie> he's not even talking about directories i think[18:38:07] <_W_> ~~sproingie jws[18:38:07] <javabot> sproingie, jws is a powerful deployment mechanism that is much better than applets because it removes the browser incompatibility hell and you can run any swing app with a main() method without modification. see http://java.sun.com/javase/6/docs/technotes/guides/javaws/index.html[18:38:08] <waz> that's not an OS concept[18:38:10] <sproingie> i think he's talking about URL[18:38:21] <Woot4Moo> sporingie he has to be[18:38:30] <sproingie> i dunno if there's any way to ask a servlet where it's mounted[18:38:30] <Woot4Moo> then he should have declared that its a webapp[18:38:39] <sproingie> actually don't need to, just ask for the request URI[18:38:48] <_W_> waz, so applications run from, say init, in linux, don't have a current working directory?[18:39:33] <waz> applications do[18:39:45] <_W_> any process do[18:39:47] <waz> nevermind this whole discussion is idiotic[18:40:04] *** NiallC has quit IRC[18:40:27] *** valcker has quit IRC[18:41:34] *** sepult has joined ##java[18:41:55] <gabbah> enhance your calm... :)[18:42:55] <razel> i have a public class ClassA with private fields...i want to create a duplicate class ClassB that is exactly ClassA and an extra method which i will insert. I tried class ClassB extends ClassA but it claims "var_x has private access in ClassA"[18:43:00] <razel> how would i do it[18:43:21] <dmlloyd> ~~ razel private[18:43:21] <javabot> razel, private is a keyword representing one of the four access levels in Java. A private member is visible only to the enclosing class, or to any other classes defined within the same file. Instance fields should generally always be private. See "~access level" for more information.[18:43:47] <razel> i know what private is...[18:43:56] <skypce> hi, helpme please with this, i want sort header cols in mi table ;: http://www.pastie.org/401132[18:44:01] <marvi> razel: No, you don't.[18:44:12] <razel> yes i do[18:44:23] <gabbah> razel, then you need to use protected, or no modifier at all (if in same package)[18:44:24] <razel> i think you dont understand my question[18:44:26] <waz> you fooled us then with your question[18:44:34] <razel> ok[18:44:38] <waz> that was another way of stating 'I don't understand private'[18:44:52] <razel> lets put it this way...i want to clone class A[18:45:01] <razel> with a different name classB but the contnents the same[18:45:14] <razel> sort of like copy[18:45:34] <razel> can i do it ?[18:45:42] <marvi> cp A.java B.java[18:45:56] <gabbah> hehe[18:45:58] *** KikiJiki has quit IRC[18:46:07] <razel> do you understand my question ?[18:46:13] *** w0lfshad3 has quit IRC[18:46:21] <waz> heh[18:46:30] <marvi> razel: Nope.[18:46:44] <gabbah> if you want to "clone" it, then just copy paste... just copy the contents[18:46:50] <razel> ok[18:46:56] *** LouisJB has quit IRC[18:46:57] <razel> thank you[18:46:59] <gabbah> or like marvi said...[18:47:34] <marvi> razel: your first question sounded like you wanted to inherit. Then you said clone. Then copy.[18:47:42] <gabbah> however, this might be a bad idea in the long run for you. perhaps you will have to make a change in two places later.. depending on how you use the classes[18:47:58] <gabbah> that is what inheritance is for[18:48:19] <razel> but inheritance doesnt include the private fields[18:48:22] <gabbah> to avoid maintaining a lot of code, and copy pasting a lot[18:48:22] *** Vantaa has joined ##java[18:48:48] <gabbah> well, maybe those field shouldn't be visible in subclasses for a reason[18:48:57] <gabbah> or, if they should, make them protected[18:49:05] <Woot4Moo> default access not protected[18:49:15] *** BlindHunter has quit IRC[18:49:20] <gabbah> well that also depends[18:49:34] <waz> heh[18:49:35] <gabbah> default access forces subclasses to be in the same package[18:49:42] <waz> inheritance does include the fields![18:49:43] <Woot4Moo> yeah one of them there good design concepts[18:49:43] <gabbah> perhaps he doesn't want that[18:49:58] <Woot4Moo> then he should make an abstract class[18:50:05] <reisi> can anyone using logback 0.9.15 confirm that org.sl4j.MDC.remove(String) doesn't work?[18:50:07] <waz> and if you understood private you'd understand how[18:50:37] *** bhz- has quit IRC[18:50:55] <gabbah> razel, the fields are there, they are just not visible to you in the sublcass if they are private[18:51:07] <waz> bingo![18:51:11] <waz> but they are still there[18:51:21] *** WsootBakc has joined ##java[18:51:38] <WsootBakc> hi, i need help, anyone please ?[18:52:05] <Woot4Moo> hi[18:52:08] <gabbah> we will all die to help you[18:52:09] <Woot4Moo> dont ask to ask[18:52:17] <WsootBakc> thanks :)[18:53:19] <razel> u said something about abstract class[18:53:20] <razel> what is that[18:53:26] *** nijm has joined ##java[18:53:39] <Woot4Moo> hmm[18:53:43] <Woot4Moo> whats up razel?[18:53:54] <gabbah> that's a later lesson razel :)[18:53:57] <waz> ~aolbonics[18:53:57] <javabot> waz, aolbonics is using unnecessary abbreviations such as 'u', 'r', 'ur', 'thx', etc. Using this language depicts you as an imbecile in the eyes of the helpful regulars in this channel, and is generally not tolerated. If you want intelligent answers, the least you can do is speak intelligently. Additionally arguing about this rule will get you nowhere except banned. Have a nice day![18:54:02] <razel> lol[18:54:12] <razel> brb in 20 min[18:54:19] <gabbah> just focus on private field for the moment :)[18:54:30] <WsootBakc> ok, I'm at school, and need to sort a Linked List, I build the linked list. In the list, i got Objects. these Objects.getX return a double. I need to sort the Linked list from the lower getX() to the last one (and sorry im not english :-) )[18:54:34] <Woot4Moo> or in fact dont use clone()[18:54:36] <Woot4Moo> because its horrible[18:54:51] <Woot4Moo> its impossible[18:55:28] <goki-_-> clone doesn't do anything useful[18:56:49] <gabbah> WsootBakc, i think your objects need to implement the comparable interface[18:57:21] <gabbah> if you want to use a built in sort method[18:57:30] *** redrebel has joined ##java[18:58:06] <WsootBakc> oh, ?[18:58:12] <Woot4Moo> linkedList doesnt have an api sort method[18:58:27] <whaley> ~~ Woot4Moo javadoc Collections[18:58:28] <javabot> Woot4Moo: http://is.gd/jbSy [java.util.Collections][18:58:32] <gabbah> I was thinking of Collections[18:58:32] <Woot4Moo> thanks i can read[18:58:57] <whaley> WsootBakc, rather ^[18:59:12] <whaley> your names looked equally ridiculous, so I didn't know who to direct that to[18:59:28] <Woot4Moo> http://java.sun.com/j2se/1.4.2/docs/api/java/util/Collection.html[18:59:44] <Woot4Moo> as its school it is undoubtedly Collection not Collections[18:59:44] <gabbah> 1.4[19:00:13] <Woot4Moo> yeah the interface didnt change for 1.6 :)[19:00:23] <WsootBakc> Thanks you guys ! Found it =D[19:01:02] <Woot4Moo> but good to know about Collections[19:01:21] <whaley> Woot4Moo: useful class of utlity methods[19:01:36] <Woot4Moo> whaley: Very much so, great way to fail an assignment though[19:01:57] <gabbah> he will still need collections for the sorting, right?[19:02:03] <Woot4Moo> no[19:02:08] <Woot4Moo> he has to implement it himself[19:02:13] *** mitchnull has joined ##java[19:02:15] <Woot4Moo> or that teacher is retarded[19:02:19] <whaley> Woot4Moo: that's the implementers fault for taking a class that requires assignments in java which reinvent the wheel[19:02:24] <gabbah> well depends on the assignment[19:02:34] <Woot4Moo> yes yes it is[19:02:48] <Woot4Moo> it might be an algorithms class though[19:02:53] <Woot4Moo> good to learn bubble sort[19:03:08] <gabbah> you're just guessing :)[19:04:04] *** teralaser has joined ##java[19:04:12] <goki-_-> If you want to use Java to teach basic algorithms, you need to reinvent the wheel, really[19:04:12] <Woot4Moo> at what[19:04:15] <marvi> What the teacher probably is after is for you to implement comparison on the getX. So Comparable || Comparator + Collections sounds fine.[19:04:46] <Woot4Moo> i doubt highly as he EXPLICITLY was required to use LinkedList regardless of the fact that its within Collections[19:04:53] <gabbah> marvi that is my gues as well[19:04:57] *** jorgenpt has joined ##java[19:05:02] <goki-_-> The problem is if they don't make clear exactly what constraints they put on the implementation[19:05:07] <marvi> TreeSet sounds better in that case.[19:05:11] <jorgenpt> Does this() inside a constructor invoke another constructor during the current "construction"?[19:05:31] <gabbah> marvi either way he needs to implement comparable[19:05:36] *** lem has joined ##java[19:05:48] <marvi> gabbah: yeah.[19:05:49] <gabbah> jorgenpt, yes[19:05:57] <jorgenpt> Nice. \o/[19:06:29] <jorgenpt> Thanks. I didn't know what to google for, and some hits I got said it wasn't possible to invoke another constructor during construction.[19:06:46] *** sepult has quit IRC[19:07:11] <Woot4Moo> doesnt this() in the constructor just saying use the current instantion of the object[19:07:24] <dmlloyd> no[19:07:26] <Woot4Moo> err the values it has[19:07:33] <dmlloyd> it means call another constructor on this same class[19:07:45] *** KermitTheFragger has quit IRC[19:08:00] <gabbah> you are thinking of keyword this, not this()[19:08:04] <magmarules> guys, when i have: ConcreteClass extends AbstractClass and then (AbstractClass)ConcreteClass,, is there a way i can make him call the functions of the concrete one ?[19:08:21] <dmlloyd> gabbah: what? "this" is a keyword even in a "this()" construct[19:08:30] <dmlloyd> gabbah: and this() does exactly what I said[19:08:44] *** vsayikiran has joined ##java[19:09:41] <gabbah> yes i wasn't talking to you dmlloyd, and anyway i was kind of fuzzy, but i think Woot4Moo got it anyway[19:09:52] <dmlloyd> magmarules, the type of a reference (ConcreteClass vs AbstractClass) doesn't change the type of object (which is always ConcreteClass if it was constructed via new ConcreteClass())[19:09:56] <vsayikiran> if i want to execute a class file which requires many jar files then can i run this command java -cp *.jar classfilename.class[19:10:00] <dmlloyd> ah ok[19:10:10] <magmarules> dmlloyd: found it =) need to make the method abstract too =P[19:10:52] <dmlloyd> ~abstract[19:10:52] <javabot> dmlloyd, abstract is http://java.sun.com/docs/books/tutorial/java/IandI/abstract.html[19:12:20] <vsayikiran> if i need to include multiple jar files in classpath to run a class file which is correct:1) java -cp 1.jar:2.jar:3.jar:. classfilename or java -cp *.jar classfilename[19:13:08] <dmlloyd> the former will work on all JVMs. I think doing *.jar is supported now on recent JVMs? But I never do it that way, I always list them individually[19:13:12] *** jorgenpt has left ##java[19:13:44] *** ankylose has quit IRC[19:13:49] * cheeser nods.[19:13:56] *** _stijn_ has joined ##java[19:14:18] <vsayikiran> dmlloyd: so better habit is to use the first option i.e. to list individual jar file along with the dot operator to represent the current directory[19:14:23] <dmlloyd> yeah[19:14:52] <vsayikiran> dmlloyd: what do you mean by recent JVM 1.5 or 1.6[19:14:58] <dmlloyd> 1.6[19:15:12] <lem> I thought DefaultTreeModel::insertNodeInto will trigger an update of the tree itself. Is that incorrect?[19:15:43] <dmlloyd> ~::[19:15:43] <javabot> dmlloyd, :: is a C++ thing. In Java we use ".".[19:16:18] *** Bevin has quit IRC[19:17:04] <lem> yeah[19:17:12] <lem> I mixed it[19:17:16] <lem> sorry for that[19:17:27] <vsayikiran> i want to understand the basics of CORBA and IDL please recommend any good books or website[19:17:52] *** ilaggoodly has joined ##java[19:18:09] <cheeser> omg.org[19:18:20] <Woot4Moo> object Management group ftw cheeser[19:18:34] <lem> it should create the appropriate event...[19:18:49] <lem> but it doesn't. I can't get my tree updated after insertion[19:19:05] <lem> I already tried nodeChanged()[19:19:28] *** sepult has joined ##java[19:19:31] *** FMJaguar has joined ##java[19:19:42] <vsayikiran> cheeser: what about IDL?....any good book anyway i will the check the website.....i need to start from basics right from scratch since i dont know CORBA and IDL[19:19:57] *** conan has joined ##java[19:20:56] *** skypce has quit IRC[19:21:11] <cheeser> vsayikiran: bn.com[19:24:41] <vsayikiran> cheeser: i can search myself that not the issue, i will get a number of books,, but i want a good book, just i recommend to read ANSI C by dennis ritchie for C language, and Core JAVA for java,,,like that[19:25:25] <gabbah> just look at amazon ratings maybe, and read the reviews[19:25:56] *** ScottG489 has quit IRC[19:26:44] <magmarules> guys is there any way i can find out classes that implemented a specific interface ?[19:27:16] <cheeser> scan your classpath[19:27:29] <magmarules> ok =)[19:28:20] *** doc`` has joined ##java[19:28:54] *** benny269 has quit IRC[19:30:18] *** Ivellina has joined ##java[19:31:02] *** wans has quit IRC[19:31:02] *** marvi has quit IRC[19:31:06] *** javahorn has joined ##java[19:31:32] *** bas-i has quit IRC[19:32:26] *** Seldon75 has joined ##java[19:34:25] <yrlnry> If an object has a toString() method defined, how can I get the behavior of the default toString() on it?[19:34:40] <r0bby> yrlnry: super.toString()[19:34:46] <yrlnry> Thanks.[19:34:57] <cheeser> from within the overridden toString().[19:34:58] <r0bby> ~~ yrlnry super[19:34:58] <javabot> yrlnry, super is a reference to the parent class in which you're inheriting from. For more information see http://mindprod.com/jgloss/super.html and also see ~inheritance[19:35:05] <cheeser> externally you can't get at it.[19:35:21] <yrlnry> cheeser's answer is the one I needed. Thanks.[19:35:28] <Seldon75> hmm, if I have a class A that uses factory B to create instances of C, and C objects need to call some methods on A, is it acceptable for A to pass a reference to itself to B so B can pass it to every C it creates? This seems spaghetti like[19:35:31] <cheeser> i thought it might be[19:35:32] <cheeser> 8^)=[19:35:43] <svm_invictvs> Hola[19:35:44] <svm_invictvs> *yawn*[19:35:49] <svm_invictvs> *stretch*[19:35:56] <Seldon75> I could use Spring[19:36:12] <Seldon75> but if theres another common acceptable way to get around this, I'd like to know[19:36:32] <yrlnry> But in this case what I really want is to print out some sort of object identity so that I can see if this object is the same as some other object of the same type elsewhere in the program. So I could use the .hashCode() method, couldn't I? Or would that change if the object's contents changed?[19:36:55] *** sepult has quit IRC[19:37:04] <r0bby> hashCode() and equals()[19:37:09] <csgeek> anyone know how to prevent ant from including duplicates in a jar file?[19:37:22] <csgeek> ie.. change the behavior to update rather then add[19:37:31] <r0bby> csgeek: there's an exclude property -- look it up[19:37:47] <r0bby> ~ant manual[19:37:47] <javabot> r0bby, ant manual is http://ant.apache.org/manual/[19:38:16] <r0bby> excludesfile... right there in the manual[19:38:24] <r0bby> http://ant.apache.org/manual/CoreTasks/jar.html[19:38:39] <r0bby> bookmark that csgeek[19:39:01] <cheeser> ~mock r0bby[19:39:02] * javabot points at r0bby and says "you're a 'tard"[19:39:05] <csgeek> hmm.. I don't think that's what i'm looking for.. I want the file included.. it's just archiving foobar.class twice for some reason[19:39:20] *** The_Birdman has quit IRC[19:39:31] <cheeser> csgeek: r0bby's like that sometimes. he answers what he wants to answer regardless of the actual question[19:40:12] <csgeek> but thankyou for the link[19:40:15] <cheeser> csgeek: use update="true" in your <jar> calll[19:41:19] * r0bby needs to just shut up 99.9999999999999% of the time[19:41:48] <cheeser> or just read then speak.[19:41:56] *** vsayikiran has left ##java[19:42:10] <r0bby> :/[19:42:51] *** marvi has joined ##java[19:43:03] *** ankylose has joined ##java[19:44:23] *** milligan_ has quit IRC[19:44:57] *** arpu has quit IRC[19:45:33] *** arpu has joined ##java[19:46:43] *** cantoma has joined ##java[19:47:19] *** justafish has quit IRC[19:47:30] <csgeek> I have a ... simple enough .xml file generated by eclipse that creates a runnable jar file. I've update the jar to be "update".... for some reason.. I'm sitll seeing it call jar twice. I can't quiet figure out where the second call is coming from.[19:47:45] <csgeek> the 1st go it says Updating Jar: then 2nd one: Building Jar:[19:47:58] <Woot4Moo> well after you update it you have to rebuilt it[19:48:02] <Woot4Moo> build*[19:48:11] *** Seldon75 has quit IRC[19:48:23] *** pa has quit IRC[19:48:31] <csgeek> http://pastie.org/401219[19:48:49] *** timte has joined ##java[19:48:56] <csgeek> hmm.. maybe.. but it still includes duplicates[19:49:47] <Woot4Moo> why dont you delete the jar initially then re append[19:50:28] *** pa has joined ##java[19:51:39] *** systat has joined ##java[19:52:10] <csgeek> deleted jar, running it again... and it includes duplicates sitll[19:53:05] *** cantoma has left ##java[19:53:07] *** spathi has quit IRC[19:53:59] *** gregor_k has joined ##java[19:54:14] *** bas-i has joined ##java[19:55:27] *** MacFlecknoe has joined ##java[19:58:15] *** conan has quit IRC[19:58:20] *** nocture has joined ##java[20:02:42] *** vix85 has joined ##java[20:05:27] *** marvi has quit IRC[20:06:24] *** HeatHawk[AP2] has quit IRC[20:08:27] *** HeatHawk[AP2] has joined ##java[20:08:58] *** MacFlecknoe has quit IRC[20:09:37] *** kane77 has joined ##java[20:10:25] *** FMJaguar has quit IRC[20:12:28] *** conan has joined ##java[20:12:30] *** Resistance has joined ##java[20:14:31] *** Yustme has joined ##java[20:18:17] *** ridoo has quit IRC[20:18:57] *** Galik has joined ##java[20:19:16] *** FMJaguar has joined ##java[20:20:58] *** marvi has joined ##java[20:24:20] <tieTYT> are anotations inherited?[20:24:24] <tieTYT> on methods and classes?[20:25:03] <dmlloyd> it depends[20:25:23] <dmlloyd> ~~tieTYT javadoc java.lang.annotation.Inherited[20:25:25] <javabot> tieTYT: http://is.gd/l03q [java.lang.annotation.Inherited][20:26:01] *** sepult has joined ##java[20:26:10] *** NiSoOo has joined ##java[20:27:55] *** bas-i has quit IRC[20:29:26] <marvi> Is there any work going on to modernise (or replace) the Javabean specification? We use it pretty heavily in out component model, and there are so many things that could be improved.[20:30:02] *** COM-S|Hokar has quit IRC[20:31:09] <cheeser> like?[20:31:50] <marvi> Well a small thing: bigger icons. :)[20:32:05] <cheeser> the javabean spec has nothing to do with icons[20:32:06] *** magmarules has quit IRC[20:33:04] *** lolzie has joined ##java[20:33:08] <lolzie> Hi all[20:33:15] <marvi> cheeser: you don't consider BeanInfo to be part of the Javabean spec?[20:33:37] <cheeser> ~beans[20:33:38] <javabot> cheeser, beans spec is http://java.sun.com/products/javabeans/docs/spec.html[20:33:56] *** Galik has left ##java[20:34:14] <lolzie> Is it possible to use something like methodName({"Element1", "Element 2"}); for a public static void methodName (String[] arg); ?[20:34:24] <cheeser> ~tias[20:34:24] <javabot> Try it and see. You learn much more by experimentation than by asking without having even tried.[20:34:40] <lolzie> cheeser: thanks but I did, that's why I said /like/, need to know if there's a working alternative[20:35:23] <marvi> cheeser: yes, it talks about BeanInfo.[20:36:39] <cheeser> lolzie: try explaining the problem[20:37:38] <cheeser> marvi: oh, for the bean builder bit?[20:38:07] <marvi> cheeser: Yes, it is more then getters and setters and an empty constructor.[20:38:20] <marvi> than.[20:38:25] <lolzie> cheeser: the problem I am encountering is that I'd like to pass an anonymous String array as a single argument to a method - however, using the syntax above, it does not compile[20:38:34] <cheeser> you're free to write your code however you want. i don't know that anyone really uses that for anything more than a bean definition anyway.[20:38:48] <cheeser> ~~ lolzie show us[20:38:48] <javabot> Paste the code (and any errors) in the pastebin where we can see it. See ~pastebin for options. Also see ~testcase for good examples as to how to help us help you quickly diagnose and solve problems.[20:38:56] *** lem has left ##java[20:38:58] <cheeser> lolzie: try new String[] { ... }[20:39:12] <lolzie> I already did show you...[20:39:19] <lolzie> Then you asked for an explanation, heh[20:39:40] <marvi> cheeser: well, I think there is a need for a standard component framework. My guess is that the properties debate stalled everything and it died.[20:39:40] <lolzie> Hmm, will do[20:39:48] <cheeser> lolzie: let's try it this way: show. us. the. error.[20:40:06] <cheeser> dear lord. it's like i'm talking to my cousin's kids or something.[20:40:07] <cheeser> 8^)=[20:40:34] <svm_invictvs> heh cheeser[20:40:37] <lolzie> Yeah yeah, well I've made it quite clear that the syntax is invalid and that I'm looking for an alternative method of doing it[20:40:44] <lolzie> It's really not like I'm acting like a child here[20:40:48] <cheeser> ~~ lolzie paraphrase[20:40:48] <javabot> Don't paraphrase code or errors. If you knew what was important to show us, you wouldn't need us to answer your question. You should pastebin the *actual* code and the *actual* error. Anything else is most likely going to be useless.[20:41:12] <lolzie> The precise error is 'test.java:3: illegal start of expression methodName({"Hello", "There"});'[20:41:14] *** Weems has quit IRC[20:41:20] <cheeser> yay![20:41:25] <cheeser> now change it how I told you[20:42:26] *** trustin has quit IRC[20:44:31] <jottinger> lolzie: pastebin?[20:44:36] <jottinger> or something readable?[20:45:19] <lolzie> cheeser: cheers, works. If using an int[] as an argument instead, why is the `new' necessary?[20:45:31] <jottinger> depends on what you're doing[20:45:44] <lolzie> i.e. methodName(new int[] {1, 2})[20:46:03] <jottinger> lolzie: just specific declarative types[20:46:13] *** jbwiv has quit IRC[20:46:16] <jottinger> what people usually want when they bitch about java's verbose syntax is, well, groovy[20:46:37] <Nebulam> because an array is an object lolzie[20:46:41] *** jbwiv has joined ##java[20:46:55] <Nebulam> hence the methods and properites :)[20:47:02] <lolzie> Aha, gotcha[20:48:18] *** dunmer has joined ##java[20:49:04] <dunmer> hello, does anybody have compiled jpcap from source on 64bit linux system? is it possible?[20:49:05] *** spathi has joined ##java[20:49:08] *** [[thufir]] has joined ##java[20:52:11] *** tomvolek has joined ##java[20:52:44] *** dunmer has quit IRC[20:53:50] *** dunmer has joined ##java[20:56:36] *** cyzie has quit IRC[20:58:48] *** Mortomes has quit IRC[21:00:31] *** trustin has joined ##java[21:00:34] *** TooAngel has joined ##java[21:06:02] *** mmc has quit IRC[21:07:24] *** aksn has joined ##java[21:11:05] *** acuster has quit IRC[21:13:38] *** idea4good has joined ##java[21:14:18] <idea4good> http://java.pastebin.ca/1348091[21:14:41] <idea4good> I am getting class cast exception not sure if i ma passing the rite thing to restriction.like()[21:15:28] *** morkar- has joined ##java[21:15:31] <vol> stick this on seperate lines and pop through with a debugger[21:16:22] <idea4good> they are in diferent methofs[21:16:27] <idea4good> *methods[21:18:53] *** eduardopl has joined ##java[21:18:58] *** lenni_-_ has joined ##java[21:19:28] *** adi112358 has joined ##java[21:19:56] *** elindio has quit IRC[21:21:00] *** Mortomes has joined ##java[21:21:33] *** balu2 has joined ##java[21:22:59] *** balu2 has left ##java[21:26:15] *** wooli has joined ##java[21:26:45] <wooli> i wish "".split(",").length; would return 0.[21:27:39] <_W_> and ",".split(",").length() 1?[21:28:11] *** Seldon75 has joined ##java[21:28:48] *** vix85 has quit IRC[21:29:45] <slango> if I am painting on a jPanel, how can I clear the jPanel when I repaint?[21:30:53] <dmlloyd> call repaint on the jpanel, not on your component?[21:31:11] <slango> what component?[21:31:29] <slango> i'm overriding paintComponent() in the jpanel[21:31:36] <slango> is that not the right way to do it?[21:31:58] <dmlloyd> no, not unless you're creating your own panel implementation[21:31:58] *** bas-i has joined ##java[21:32:10] <dmlloyd> the usual way is to implement a component, and put the component *in* the panel[21:32:17] <dmlloyd> ~~ slango swing tutorial[21:32:17] <javabot> slango, swing tutorial is the tutorial from Sun on how to 'Create a GUI with JFC/Swing': http://java.sun.com/docs/books/tutorial/uiswing/[21:32:31] <slango> dmlloyd, what type of component should I be painting on? all I'm using this for is a canvas for painting[21:32:40] <slango> which needs to completely fill the jpanel[21:32:48] <cheeser> wooli: "" is a valid String so splitting on "," has 1 one element.[21:32:57] <cheeser> that's entirely consistent[21:33:01] <dmlloyd> slango: a JComponent[21:33:08] *** ankylose has quit IRC[21:33:08] *** RLa has quit IRC[21:33:09] <wooli> "" has 1, but "," has 0[21:33:09] <dmlloyd> that's what I'd do anyway[21:33:15] *** Sagi22 has quit IRC[21:33:17] <dmlloyd> then put it on the JPanel[21:33:27] *** fedora-geek has joined ##java[21:33:42] <cheeser> wooli: ? "," has 0? what does that mean?[21:33:42] *** lukev has joined ##java[21:33:51] <wooli> ",".split(",").length returns 0[21:34:05] <fedora-geek> hi all , I use commands through java , But how to set environement variable for my coomand to use, on Linux[21:34:13] *** eventualbuddha has quit IRC[21:34:38] *** lukev has left ##java[21:34:47] *** Nebulam has quit IRC[21:35:24] <wooli> "a".split(",").length should be 1. "".split(",").length should be 0. ",".split(",").length should be 0 too[21:35:27] *** hiredman has quit IRC[21:35:35] <wooli> in my world :P[21:35:42] *** hiredman has joined ##java[21:36:21] <wooli> but if java is going to count "", then ",".split(",").length should be 2[21:37:26] <jdolan_> can anyone point me to a very basic Spring webapp simply for dependency injection? i don't need MVC. i'd just like to manage my <beans> :)[21:38:03] *** Seldon75 has quit IRC[21:38:05] <cheeser> wooli: now that I can agree with. i'm not sure what's going on there.[21:38:50] <cheeser> ~~ jdolan_ qwicket[21:38:50] <javabot> Qwicket is a quickstart application for building a basic spring+hibernate+wicket application quickly. It can be found at http://qwicket.sf.net.[21:38:59] <wooli> :)[21:40:20] *** ankylose has joined ##java[21:40:30] <cheeser> gah. enough training courses. back to code.[21:40:31] *** dude7064 has quit IRC[21:40:56] <jdolan_> cheeser, perfect![21:41:02] <jdolan_> ty.[21:41:07] <cheeser> i know! P^)=[21:41:32] <jdolan_> is that a winking dude with a beard?[21:41:49] <jdolan_> or eye patch + beard even?[21:41:55] * jdolan_ fails[21:42:21] *** fedora-geek has left ##java[21:42:24] *** Sulis has quit IRC[21:42:28] <cheeser> wink+goatee[21:42:58] *** eduardopl has quit IRC[21:43:04] <dmlloyd> O^)=[21:43:07] <dmlloyd> alien version[21:43:16] *** lenni_-_ has quit IRC[21:43:31] <cheeser> dmlloyd: or mythological[21:43:38] <dmlloyd> sure[21:43:53] <slango> dmlloyd, now I'm not seeing any output at all[21:44:22] *** benny`work has joined ##java[21:44:27] <idea4good> od Can't i use Hibernate.Restriction api for dates bcz docs say i can use any object[21:44:32] <dmlloyd> Ю8^)=[21:44:41] <cheeser> idea4good: "because"[21:44:55] <idea4good> sorry dont kick me pleaseeeeeeeeeeeee[21:45:01] <dmlloyd> ...[21:46:18] <idea4good> http://java.pastebin.ca/1348126[21:46:31] <idea4good> restriciton.like returns ClassCastException[21:46:44] <idea4good> and restriction.gt or restriction.lt return nothinh[21:46:59] <idea4good> so i was wondering what should i be using for Dates[21:47:06] <cheeser> a Date[21:47:18] <cheeser> "like" on a date makes zero sense, though.[21:47:37] *** TooAngel has left ##java[21:47:40] <idea4good> yes Date didnt get any til now niether in my prog nor in my life ;)[21:48:01] <idea4good> yes so i tried gt and lt[21:48:10] <idea4good> but not sure if that would work either[21:48:22] <idea4good> greater and less than[21:48:34] <cheeser> typically you use between for dates[21:48:48] <cheeser> depends on how you're storing dates in the db[21:48:52] *** jchauncey has quit IRC[21:49:19] <idea4good> yes but i want all rows after a particlular hire date[21:50:00] *** T-Hawk has joined ##java[21:51:14] <csgeek> I have a JToolbar that I need to put on a form that'll contain a GidBagLayout ... how do I set it so the toolbar doesn't expand with the form?[21:51:17] <cheeser> so use great than[21:52:01] <cheeser> csgeek: put the toolbar row in a layout where you toolbar can stay fixed with padding on the right that grows with the container[21:53:05] *** fedora-geek has joined ##java[21:54:15] <fedora-geek> hi all , I execute system commands using java , but how to set environment variable to use it inside the java app?[21:55:49] *** Level1 has joined ##java[21:56:07] <lolzie> http://java.sun.com/docs/books/tutorial/essential/environment/env.html[21:56:10] <lolzie> That of relevance to you?[21:56:21] <Craghag> where java web start stores the resources?[22:01:02] *** javahorn has quit IRC[22:02:37] *** nmbr has left ##java[22:03:19] *** kwvarga has quit IRC[22:03:50] <Craghag> can't find it[22:05:27] *** CrypticSquared has joined ##java[22:09:58] *** sebr_afk is now known as sebr[22:11:28] *** roue has joined ##java[22:12:48] *** nvictor has joined ##java[22:13:21] *** sombriks has quit IRC[22:13:45] *** sombriks has joined ##java[22:14:25] *** NiSoOo has quit IRC[22:14:30] <genesiss> what is the easiest way to make a copy of existing Vector object?[22:16:47] *** gabbah has quit IRC[22:16:59] *** nvictor has left ##java[22:17:25] <cheeser> new ArrayList(vector);[22:18:52] *** Pyretic has joined ##java[22:19:11] *** T-Hawk has quit IRC[22:19:47] <Pyretic> is it possible to have a seperate thread painting on a jpanel ?[22:19:49] *** djp[mbp] has joined ##java[22:20:31] *** Craghag has quit IRC[22:20:47] *** Aquanox has quit IRC[22:23:50] <cheeser> all UI updates should happen on the EDT[22:24:04] *** monkeycid has quit IRC[22:24:30] <AMcBain> cheeser: we answered him in ##swin[22:24:32] <AMcBain> g[22:24:49] <cheeser> Pyretic: stop crossposting[22:24:59] * cheeser grumbles and goes back to watching maven spin[22:25:16] <AMcBain> tbh, he did at least wait a minute before going over there. :P[22:25:55] <cheeser> he waited a whole minute?!? wow![22:26:00] <cheeser> the patience of job![22:26:16] *** waz has quit IRC[22:26:29] *** mitch0 has quit IRC[22:29:48] <slango> why would calling setBackground() on a JComponent not change the background color?[22:30:14] *** bigjocker has quit IRC[22:30:51] <AMcBain> slango: try setOpaque(true) then repaint it?[22:33:57] <slango> AMcBain, that doesn't seem to be working either[22:34:30] <AMcBain> then I wouldn't know. I usually use JPanel for most things I want.[22:35:09] <AMcBain> the only thing that defaults to non-opaque (that I know of) is JLabel, so my guess is that JComponent just doesn't paint anything at all.[22:35:56] <AMcBain> I think that's the most likely cause, because if other things extend that, it doesn't really have anything specific that it should be painting ...[22:36:37] *** azanar has quit IRC[22:36:38] <slango> AMcBain, well, I overrided the paintComponent() method[22:36:43] *** Level1_ has joined ##java[22:36:47] <AMcBain> that would explain it[22:37:02] <AMcBain> it's not going to paint anything if you don't call super.paintComponent(g)[22:37:21] <slango> AMcBain, I do[22:37:27] <slango> :-/[22:37:34] <AMcBain> then, as I said before, try extending JPanel.[22:37:38] <slango> it's painting everything BUT the background just fine[22:37:40] <AMcBain> you'll probably have a lot more luck.[22:37:49] *** isr` has joined ##java[22:37:59] <slango> ugh... I was extending JPanel... but someone in here told me to extend JComponent[22:39:15] <slango> but that did cure it[22:39:31] <WsootBakc> is there a rule on how to name the class that will contain main() ?[22:39:40] <isr`> does anyone have a good way to stop a JScrollBar from bouncing when implementing a pan[22:40:03] <AMcBain> WsootBakc: not that I know of.[22:40:16] <isr`> ~pastebin[22:40:17] <javabot> http://pastebin.stonekeep.com Paste the final url after you've pasted your stuff there.[22:40:30] <AMcBain> slango: if you are insistent on using JComponent, you could paint the background yourself[22:40:36] <WsootBakc> AMcBain : ok, ty[22:40:39] <AMcBain> (rather than using JPanel)[22:41:03] <slango> AMcBain, I don't care what I use... as long as it works[22:41:14] <AMcBain> then you're fine :)[22:41:17] <slango> it's a homework thing, so the amount that I care about quality is WAY down[22:41:51] *** arpu has quit IRC[22:42:07] <epalm> java swing homework :( how could they[22:42:10] <isr`> http://pastebin.stonekeep.com/5685[22:42:19] *** Luminari has joined ##java[22:42:21] <isr`> check out the sample output[22:42:24] <isr`> i was dragging to the right[22:42:33] *** T-Hawk has joined ##java[22:42:37] *** arpu has joined ##java[22:42:45] <Luminari> is there a java servlet that can compile java files live similiar to how you can compile jsp's live?[22:43:04] <isr`> the majority of the dx values are positive, which they should be, but some are still negative for some reason, and it makes the scroll bar jump a bit[22:43:10] <cheeser> Luminari: not that i[22:43:14] <cheeser> 'm aware of[22:43:31] <Luminari> cheeser: all well, just figured I'd ask :)[22:44:19] <epalm> Luminari: eclipse/tomcat will notice when you save java files, and hotswap the changed file in seemlessly[22:44:33] <epalm> it actually works most of the time[22:45:25] <Luminari> epalm: if only I used either eclipse or tomcat, since I use glassfish and netbeans :)[22:46:07] <isr`> any ideas?[22:46:22] *** vezzoni has quit IRC[22:46:28] <fedora-geek> Hi all , I use SWT ,I created area of type Text to display data on it , how to make lines warp in it ?[22:46:38] <marvi> JavaRebel is some kind of commercial hotswap implementation.[22:46:42] <AMcBain> warp? that's easy: take some drugs.[22:47:17] <epalm> Luminari: well why'd you ask if you're already stuck using what you've got[22:48:10] <isr`> can anyone help me?[22:48:13] <fedora-geek> AMcBain,OOPS i mean wrap :)[22:48:50] * AMcBain wonders if it's possible to produce /good/ code while high[22:49:01] <Luminari> epalm: I asked if there was a servlet that compiled, which shouldn't actually preclude me switching servers[22:49:04] <fedora-geek> ?![22:49:11] <isr`> AMcBain: it is[22:49:14] *** blahjake has joined ##java[22:49:21] <isr`> http://pastebin.stonekeep.com/5685 can anyone help me figure this out[22:49:32] <AMcBain> isr`: I've seen drunk programmers on IRC, so I figured someone somewhere's done it while high[22:49:43] <isr`> im sure a lot of people do[22:49:48] <isr`> in fact, i know some people who did[22:49:51] *** wooli has left ##java[22:49:55] <isr`> not for work or anything[22:50:11] <fedora-geek> hi all is there's any SWT here ?[22:50:24] <AMcBain> if someone knows the answer, they'll speak up[22:50:43] <epalm> fedora-geek: you're asking about a Text element wrapping text. how can google not have an immediate answer to this?[22:50:58] <isr`> AMcBain: do you know the answer?[22:51:00] <isr`> i know you do[22:51:03] <isr`> dont lie to me![22:51:09] * isr` holds knife to AMcBain's throat.[22:51:30] <isr`> jk :-P[22:51:46] * isr` sends his 200 pound chimp after AMcBain[22:51:50] <AMcBain> I don't give answers to terrorists :P[22:51:54] <isr`> i think that might be even more terrifying[22:51:58] *** Fullma has joined ##java[22:52:24] *** Level1 has quit IRC[22:53:45] *** Razec has joined ##java[22:54:21] *** charzero has joined ##java[22:54:58] <charzero> Do anonymous classes take up space in PermGen?[22:55:04] <WsootBakc> can we talk about Compilators here ? (Eclipse)[22:55:06] <blahjake> yes[22:55:14] <blahjake> yes @ charzero[22:55:25] <WsootBakc> understood ;)[22:55:56] <blahjake> #eclipse is probably better for questions about its specific compiler[22:56:04] <cheeser> indeed[22:56:06] *** Yustme has quit IRC[22:56:13] <WsootBakc> thank you ![22:56:19] <AMcBain> isr`: what's the issue? it seems to work fine for me (once I wrote a Main, loaded up a buffered image into a ImageIcon to load into a JLabel to then send to an instance of your class which I added to a JFrame ... meaning you FORGOT to write a test case)[22:56:54] <dos000> anyone can explain the need for the queue in DispatcherEventHandler ? http://today.java.net/pub/a/today/2007/02/13/architecture-of-highly-scalable-nio-server.html[22:56:54] *** Copter has quit IRC[22:57:19] <vol> WsootBakc: you can ask about compilation problems...[22:57:40] <AMcBain> isr`: ping[22:57:43] <WsootBakc> ty vol, but it's about JUnit ;)[22:57:52] <blahjake> isr`: you should get rid of all that double and Double stuff[22:57:53] *** popcornPanic has quit IRC[22:58:00] *** sepult has quit IRC[22:58:37] *** brousch has quit IRC[22:58:51] <cheeser> what does junit have to do with ecj?[22:59:26] *** adi112358 has quit IRC[22:59:32] *** adi112358 has joined ##java[23:00:18] *** MigoMipo has quit IRC[23:00:45] *** waz has joined ##java[23:00:55] *** timte has quit IRC[23:01:57] <cheeser> 5[23:02:50] *** BeholdMyGlory has quit IRC[23:03:28] *** cher has quit IRC[23:03:35] *** [TechGuy] has quit IRC[23:03:39] *** bindaas has quit IRC[23:03:50] *** tds5016 has joined ##java[23:03:51] *** dv_ has joined ##java[23:05:06] *** da` has joined ##java[23:05:11] *** da` has quit IRC[23:07:50] <tds5016> can someone tell me what class I could use to escape a string to MySQL input?[23:08:12] <aleksei> tds5016: PreparedStatements[23:08:17] *** musically_ut has joined ##java[23:08:25] *** i-bas has joined ##java[23:08:30] *** bas-i has quit IRC[23:08:33] <waz> or just escape chars :)[23:08:44] * Stephmw shudders[23:09:06] <deufrai> tds5016: try using StringEscapeUtils from the apache commons-lang library[23:09:21] <tds5016> thanks deufrai[23:09:29] <tds5016> waz: I'm not in control of what users input...[23:10:42] * cheeser eyes deufrai[23:10:48] <cheeser> use a PreparedStatement[23:11:42] <waz> heh[23:11:46] <tds5016> will a prepared statement automatically escape the strings correctly?[23:11:52] *** sepult has joined ##java[23:11:58] <waz> have you read the docs?[23:12:12] <waz> and do you know what a prepared statement is?[23:12:41] *** EdwardIII has joined ##java[23:12:43] <EdwardIII> hola[23:12:48] <waz> que tal?[23:13:01] <EdwardIII> si si[23:13:07] <deufrai> [threads and singleton] hi guys. I'm having a bunch of threads that are working on a large data list (reads only). This list is initialized in my Datasore (singleton) constructor. I'm surprised to see that all threads gently wait for the Datastore constructor to end.[23:13:23] <EdwardIII> bien[23:13:30] <tds5016> This is kind of a complex query for a prepared statement?[23:13:44] <waz> how would we know?[23:13:46] *** Woot4Moo has quit IRC[23:13:51] <tds5016> waz: not yet, I was just asking, because if I run into the same issue....[23:14:23] <deufrai> can someone explain why to my thread noobness ?[23:14:51] <cheeser> ~anyone[23:14:51] <javabot> Instead of asking whether anyone works with something you need help with, please save time by asking your actual question. If someone knows and wants/has time to help, perhaps he/she will.[23:14:53] <waz> deufrai: pastebin the code[23:15:18] *** charzero has quit IRC[23:15:29] <tds5016> waz: I meant.... it is a complex query for a preparedStatement, I'd like to avoid it.[23:15:48] <waz> weird[23:15:53] <tds5016> I take it there is no addSlashes() method like there is in php.[23:16:06] <waz> hahaha[23:16:11] <deufrai> waz: that's a 5 classes test case. Not easy to pastebin.[23:16:14] <Luminari> tds5016: unless your query is over a page long, I don't see what complex has to do with it[23:16:26] <EdwardIII> i'm actually looking at the best way of import data safely and escaping slashes right now tds5016[23:16:29] <tds5016> ot[23:16:35] <waz> deufrai: can't paste only pertinent info eh?[23:16:49] <deufrai> waz: Hang on ...[23:16:49] <tds5016> it has a nested select query, which would be very ugly to have a perpared statement with.[23:17:00] <EdwardIII> tds5016: the first thing i saw was this: http://en.wikipedia.org/wiki/SQL_injection <- which seems to imply that using prepared statements is the best way to handle this unless you want to write it yourself[23:17:09] <Luminari> tds5016: what is your logic for why thats uguly?[23:17:27] <EdwardIII> but i just checked out the preparedStatement section in the API and it doesn't state that it does any data cleansing[23:17:31] <tds5016> hard to understand when maintaining.[23:17:36] <EdwardIII> so i'm going to try it and see[23:17:39] <blahjake> tds5016 it will be less ugly than having your DB get owned[23:17:48] <tds5016> blahjake: you're right.[23:18:12] <tds5016> hence asking if there was a way aside from a prepared statement.[23:18:14] <Luminari> tds5016: do a quick google search for Named Parameter Statement[23:18:19] <tds5016> if there's not, then that's understandbale.[23:18:43] *** red-lichtie has joined ##java[23:18:46] <reverend> i'm still amazed that after years of having the issue pretty much solved and commonly accepted, php managed to bring the old 'string concatenation sql statement' chestnut back to life.[23:19:10] <EdwardIII> yeah parameters were news to me coming from PHP originally[23:19:20] <EdwardIII> i was like "this is great, it solves many security problems, when have i never seen this before?"[23:19:24] <waz> but it has addSlashes()![23:19:26] <jdolan_> hm, Spring is failing to validate the XSD of by beans declarations because this junk i have to build on top of has an old-arse version of xerces in it.[23:19:27] <EdwardIII> heh[23:19:32] <jdolan_> is there a way to disable Spring's XSD validation?[23:19:35] <reverend> you gotta love how php just blithely eschews 60 odd years of computer science at every turn[23:19:51] *** red-lichtie has quit IRC[23:19:54] *** scott_w has quit IRC[23:19:57] *** Dewi has quit IRC[23:20:13] <jdolan_> reverend, have you never worked on a PHP app before?[23:20:13] <EdwardIII> but i guess it is super-duper quick, and that's the tradeoff[23:20:21] <jdolan_> they're all horribly broken.[23:20:34] <reverend> obviously[23:20:40] <jdolan_> Drupal, SugarCRM, ..i have yet to see one where i'm like "Oh, that's clean." lol.[23:20:47] <Luminari> tds5016: here, try this: http://pastebin.com/d44be437d[23:20:53] <EdwardIII> it does take a lot of the legwork out of development, it was a handy tool for introducing me to scripting anyway[23:21:01] <EdwardIII> but now i'm loathe to do anything with it[23:21:01] <tds5016> thanks guys.[23:21:22] <_W_> jdolan_, to be fair, a lot of Java libraries are the same[23:21:45] <tds5016> reverend: you're right; but it's fast as hell to develop in. haha.[23:22:02] *** Nebulam has joined ##java[23:22:16] <reverend> i'd disagree on that point too[23:22:20] <tds5016> I didn't want to start a holy war btw, sorry.[23:22:41] <tds5016> reverend: I know it's off topic, but I'm honestly curious as to why you think so?[23:22:48] <reverend> thre's no war, it's commonly accepted that php is absolute junk, so nobody will really argue[23:23:01] *** _acid__ has joined ##java[23:23:02] <waz> fast as hell to run poorly, be damn hard to maintain and a host of other problems too[23:23:15] <Luminari> php is pretty fast to hack together unmaintainable garbage[23:23:26] <reverend> tds5016: because slapping together and app is not the sole factor in 'fast to develop in'[23:23:30] <tds5016> reverend: I'd agree too... but it is fast to get something prototyped. haha.[23:23:37] *** Deiz has joined ##java[23:23:49] <tds5016> which is what I was referring to for the most part.[23:23:51] <EdwardIII> i have to administrate a server that hosts old PHP sites, a real nightmare[23:23:59] *** Deiz has left ##java[23:24:03] <Luminari> course you can hack together crap pretty fast in rails or django too[23:24:16] <reverend> fast to develop in if your definition of 'develop' doesn't include testing, security or maintainability[23:24:19] <tds5016> haven't used django, I've heard good things though.[23:24:23] *** nytejade has joined ##java[23:24:33] <EdwardIII> PHP has something similar, CakePHP[23:24:41] <EdwardIII> well obviously there are a ton of projects but that's the one i've seen the most of[23:24:43] <cheeser> ~interesting[23:24:44] <javabot> this is all very interesting (not really) but please take it somewhere else.[23:24:54] <tds5016> reverend: for my purposes of prototyping, no; I generally use php as a proof of concept.[23:24:58] <tds5016> not a final solution.[23:25:18] <Luminari> cheeser: what you don't like pointless language discussions?[23:25:19] <reverend> prototypes have a habit of becoming first implementations[23:25:35] <reverend> easier to do it right the first time[23:26:04] <EdwardIII> tds5016: what do you do your final implementation in? java?[23:26:08] <tds5016> but there is STILL good php code in existence. It does allow for bad code though, I will grant you that.[23:26:13] <blahjake> at any rate PHP does have prepared statements and they should be used there just like here[23:26:26] <tds5016> EdwardIII: depends on the project.[23:26:32] <tds5016> sorry. I didn't mean to change the subject, sorry all.[23:26:36] <marvi> The Swedish Pension Authority wrote a prototype in Perl and Oracle SQL. Guess what they are running seven years later?[23:26:41] *** slango has quit IRC[23:26:55] <Luminari> tds5016: considering how poor the language is, I would debate whether its possible to produce good large code[23:27:07] <waz> ~php[23:27:08] <javabot> waz, php is the solution of choice for relaying mysql errors to web users.[23:27:13] <EdwardIII> heh[23:27:18] <EdwardIII> ~perl[23:27:18] <javabot> EdwardIII, perl is part of the axis of eval.[23:27:19] *** LostMonarch has quit IRC[23:27:30] <EdwardIII> who else is in the axis?[23:27:35] <Luminari> ~python[23:27:35] <javabot> Luminari, python is a dynamic object-oriented programming language that can be used for many kinds of software development. It offers strong support for integration with other languages and tools, comes with extensive standard libraries, and can be learned in a few days. Many Python programmers report substantial productivity gains and feel the language encourages the development of higher quality, more maintainable code.[23:27:37] <tds5016> Luminari: it does exist. I promise you.[23:27:48] <deufrai> waz: http://pastebin.com/d664ebe56[23:27:50] <tds5016> heh, large projects... I doubt it. haha.[23:27:59] <EdwardIII> well python gets a much better write-up than perl i must say[23:28:06] *** yobo2 has joined ##java[23:28:20] <_W_> why does the python factoid have no reference to jython?[23:28:31] <yobo2> is there a way to run java code from a native application (e.g. written in c++)?[23:28:33] <r0bby> _W_: fix it[23:28:34] <blahjake> that python line is copied from the official website, i have my doubts about the perl one ;-)[23:28:35] <tds5016> because it's in bega?[23:28:37] <_W_> ~jython[23:28:37] <javabot> _W_, jython is at http://www.jython.org[23:28:38] <r0bby> ~~ yobo2 jni[23:28:39] <javabot> yobo2, jni is the Java Native Interface. See: http://java.sun.com/developer/onlineTraining/Programming/JDCBook/jni.html and http://java.sun.com/docs/books/jni/html/preface.html - but first ask me about JNA![23:28:41] <r0bby> ~~ yobo2 jna[23:28:41] <javabot> yobo2, jna is Java Native Access, an alternative means of using native code from within Java. See https://jna.dev.java.net/[23:28:42] <tds5016> beta*[23:28:46] *** red-lichtie_ has joined ##java[23:28:46] <yobo2> r0bby: the opposite of that[23:28:56] <tds5016> I thought it was; at least last I looked.[23:28:59] <r0bby> hrm[23:29:20] <r0bby> tds5016: is it?[23:29:25] <EdwardIII> well we are certainly getting a lot of mileage out of the bot today[23:29:35] <tds5016> r0bby: last I looked.... I'm certainly no expert.[23:29:36] <yobo2> i'm not looking for jni[23:29:38] <r0bby> javabot get around[23:29:38] *** ankylose has quit IRC[23:29:39] <javabot> r0bby, I have no idea what get around is.[23:29:58] *** WsootBakc has quit IRC[23:30:02] *** bitshuffler_ has quit IRC[23:30:11] <tds5016> javabot boobs[23:30:11] <javabot> tds5016, check this out: http://photos-a.ak.facebook.com/photos-ak-sctm/genericv2/1960/33/01AwcAX0FL7oQAAAABAAAAAAAAAAA:.jpg[23:30:18] <tds5016> it didn't do it :-/ haha.[23:30:34] <tds5016> before I open... work safe?[23:30:47] *** ChanServ sets mode: +o waz[23:30:56] <tds5016> wait wtf? there's an entry for boobs?[23:31:01] <tds5016> sorry, I'll stop.[23:31:07] *** azanar has joined ##java[23:31:27] *** systat has quit IRC[23:32:38] <r0bby> ~info boobs[23:32:38] <javabot> boobs was added by: pr3d4t0r on 11-25-2007 at 10:47 PM, EST and has a literal value of: <reply>$who, check this out: http://photos-a.ak.facebook.com/photos-ak-sctm/genericv2/1960/33/01AwcAX0FL7oQAAAABAAAAAAAAAAA:.jpg[23:33:00] <r0bby> totally work safe[23:33:09] <Luminari> tds5016: I wouldn't worry, the page doesn't open[23:33:17] <tds5016> good news.[23:33:18] <tds5016> haha.[23:34:01] <tds5016> That was pretty funny; I thought it would say it didn't know what it was.[23:34:02] <tds5016> haha.[23:34:10] <EdwardIII> ho hum... NullPointerException in main(), but no line number... odd[23:34:12] <red-lichtie_> better would be: Booby - http://en.wikipedia.org/wiki/Booby :)[23:34:20] <r0bby> EdwardIII: highly doubtable.[23:34:29] <r0bby> check if you're de-referencing anything null[23:34:51] <isr`> blahjake: why?[23:34:54] <r0bby> NullPointerExceptions are easy to debug[23:35:06] <isr`> blahjake: i mean, why get rid of the double Double stuff[23:35:08] <blahjake> isr`: because you're going int -> double -> Double -> int[23:35:14] <red-lichtie_> EdwardIII: Are you compiling with line numbers (i.e. debug information enabled) ?[23:35:30] *** _stijn_ has quit IRC[23:35:37] *** Wicked has joined ##java[23:35:43] <reisi> does someone know a working maven2 war-building plugin?[23:35:50] <isr`> blahjake: Point.getX() returns a double, not an int[23:36:06] <blahjake> isr`: Point.x and Point.y are both public and ints[23:36:13] <isr`> oh word[23:36:14] <isr`> thanks[23:36:37] <EdwardIII> red-lichtie_: i'm not explicitly compiling with or without - but i've seen line numbers for other kinds of error? main() throws Exception, not sure if that's a factor[23:36:53] <r0bby> EdwardIII: it is[23:37:08] <r0bby> that would catch NullPointerException i believe[23:37:09] *** milligan_ has joined ##java[23:37:19] * r0bby gets the gun ready[23:37:22] <milligan_> http://rafb.net/p/vCTii320.html <- Why doesn't that JMenuBar show up ?[23:37:24] <red-lichtie_> EdwardIII: Fire the app up in a debugger and set you first breakpoint at the 1st command in main[23:37:29] <EdwardIII> you're gonna shoot me?[23:37:35] <r0bby> no[23:37:35] * reisi hates maven[23:37:42] <r0bby> but somebody is gonna get shot[23:38:02] <isr`> hey joe, where you goin with that gun in your hand?[23:38:15] <EdwardIII> r0bby, red-lichtie_ i've just found the point through commenty-commenty style debugging, the source seems to be somewhere around where i try to SHUTDOWN my hsqldb so i expect something is awry there[23:38:19] <r0bby> milligan_: did you setVisible true[23:38:57] <r0bby> and it should be addMenu()[23:39:04] <red-lichtie_> EdwardIII: So the main NPE isn't in your main at all[23:39:09] <blahjake> EdwardIII: build with debug symbols[23:39:17] <EdwardIII> i need to improve my error handling knowledge anyway, it's on my todo list[23:39:26] <milligan_> r0bby, the menu needs the setVisible ?[23:39:34] <r0bby> the frame does.[23:39:40] <EdwardIII> i'm making a little personal blogging app to teach myself a little, then i plan to try and port it to my blackberry[23:39:44] <r0bby> EdwardIII: start by catching what's thrown and not being lazy[23:39:45] <milligan_> r0bby, the window pops up, and has setvisible true[23:40:05] * red-lichtie_ wonders why anyone should hsqldb in the days of derby/javadb[23:40:05] *** slango has joined ##java[23:40:18] <EdwardIII> well i figured it might be more portable red-lichtie_?[23:40:18] *** ahughes has joined ##java[23:40:20] <red-lichtie_> s/should/should use/[23:40:45] <red-lichtie_> More portable ? As in old Java version ?[23:41:03] *** melter has quit IRC[23:41:05] *** DragonLord- has quit IRC[23:41:15] <EdwardIII> red-lichtie_: as in small footprint for going across devices[23:41:24] <r0bby> EdwardIII: psst. put the derby jar on your classpath it's portable.[23:41:37] <EdwardIII> i'm speaking and working in very vauge terms here heh[23:41:47] <r0bby> no duh :P[23:42:01] <EdwardIII> i've only got as far as 'hello world' on the BB and now i'm trying to learn how java actually works by making a command line version of this[23:42:05] <EdwardIII> then there will be a marriage of the two[23:42:28] <red-lichtie_> Hello World + JDBC has to go wrong :)[23:42:35] <EdwardIII> hehe[23:43:04] <EdwardIII> it's been great fun so far actually. i also want to make my way through the GoF book at some stage[23:43:16] <milligan_> r0bby, any idea ?[23:43:40] <red-lichtie_> EdwardIII: I guess you are trying something like, "connection.close()" without checking if the connection even exists ?[23:43:46] <r0bby> milligan_: no =([23:43:58] <r0bby> compare itr to the code of the menu tutorial on the swing tutrials[23:44:01] <r0bby> ~menu[23:44:01] <javabot> r0bby, I have no idea what menu is.[23:44:05] <r0bby> ~menus[23:44:05] <javabot> r0bby, I have no idea what menus is.[23:44:09] <slango> how do I make a jbutton toggle-able?[23:44:11] <r0bby> ~jmenu[23:44:12] <javabot> r0bby, I have no idea what jmenu is.[23:44:16] <r0bby> ffs\[23:44:19] <r0bby> ~swing[23:44:19] <javabot> r0bby, swing is a windowing toolkit for Java. Tutorials: http://java.sun.com/docs/books/tutorial/uiswing/ and http://www.swingwiki.org/ also check out ##swing[23:44:23] *** ankylose has joined ##java[23:44:35] <EdwardIII> red-lichtie_: yes well i am definitely doing that - so i suppose in this instance perhaps the connection didn't get created properly for some reason[23:44:52] <r0bby> ~menus is http://java.sun.com/docs/books/tutorial/uiswing/components/menu.html[23:44:52] <javabot> OK, r0bby.[23:45:30] <idea4good> when we have annotations defined as part of java comment does compiler still understand those annotations[23:46:05] *** nocture has quit IRC[23:46:08] <blahjake> idea4good: like this? // @Foo[23:46:09] *** codethief has quit IRC[23:46:18] <idea4good> yes[23:46:23] <r0bby> blahjake: more /** @foo */[23:46:27] <r0bby> I suspect[23:46:39] <cheeser> ~~ idea4good annotations[23:46:40] <javabot> idea4good, annotations is http://java.sun.com/j2se/1.5.0/docs/guide/language/annotations.html[23:46:46] <idea4good> exactly that's what i have[23:46:46] * EdwardIII is right now refactoring the error handling so there is no more throw Exception[23:46:47] <blahjake> idea4good: then no its just a comment, if you mean what r0bby's saying those are javadoc tags and not the same[23:46:59] *** akravets has joined ##java[23:47:05] <akravets> hello[23:47:21] <AMcBain> isr`: if you're still here: http://pastebin.stonekeep.com/5686[23:47:43] <blahjake> ~tag[23:47:44] <javabot> blahjake, I have no idea what tag is.[23:47:48] <blahjake> ~javadoc tag[23:47:51] <javabot> blahjake: http://is.gd/l1Fp [org.apache.wicket.protocol.http.documentvalidation.Tag]; http://is.gd/l1Fq [javax.servlet.jsp.tagext.Tag]; http://is.gd/l1Fr [javax.swing.text.html.HTML.Tag]; http://is.gd/l1Fr [javax.swing.text.html.HTML.Tag][23:47:55] <blahjake> oops[23:48:08] <AMcBain> isr`: Instead of using the ("unstable") points given by the inner component, I go out the the parent and use the points given by the view.[23:48:15] <idea4good> oki thought // i use for single line comment and /**BS*/ for mutli line comment silly on my side[23:48:21] <blahjake> what's a good factoid name for that, tag seems too ambigious[23:48:39] <cheeser> for what?[23:48:42] <AMcBain> isr`: you are always bound to have jumpiness if you do things via differences, I've found.[23:48:49] <blahjake> javadoc tags[23:48:57] <akravets> during xml parsing of a document that has carriage returns I am loosing them to linefeeds, how can I replace carriage returns with 
 values in Xerces. Is it possible?[23:48:59] <cheeser> that sounds like a good one to me...[23:49:18] <cheeser> akravets: use CDATA and ask ##xml[23:49:24] <blahjake> starting with javadoc triggers the api search though[23:49:49] <cheeser> tricky[23:49:52] <akravets> cheeser, thanks. They would know about Java there?[23:50:00] <cheeser> akravets: they would know about xml there.[23:50:04] *** n3llyb0y has left ##java[23:50:06] <cheeser> your problem is not java related.[23:50:07] *** zophy has joined ##java[23:50:16] <red-lichtie_> milligan_: Is the JFrame even visible ?[23:50:25] <yobo2> is there a way to run java code from a native application (e.g. written in c++)?[23:50:34] <milligan_> red-lichtie_, yep. As I said, the window pops up, so that seems fine[23:50:40] *** zophy has quit IRC[23:51:17] <blahjake> javabot: javadoctags is http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/javadoc.html#javadoctags[23:51:17] <javabot> OK, blahjake.[23:51:20] *** zophy has joined ##java[23:51:23] <blahjake> ~tags[23:51:23] <javabot> blahjake, I have no idea what tags is.[23:51:29] <blahjake> javabot: tags is <see>javadoctags[23:51:30] <javabot> OK, blahjake.[23:51:37] <isr`> AMcBain: you have a better idea perhaps?[23:51:40] *** Dewi has joined ##java[23:51:42] <cheeser> ~info tags[23:51:42] <javabot> tags was added by: blahjake on 02-26-2009 at 5:52 PM, EST and has a literal value of: <see>javadoctags[23:51:43] <red-lichtie_> milligan_: Do any of your menu items have an action/listener ? Wondering if non actioned items get removed[23:51:49] *** roue has quit IRC[23:51:53] <cheeser> ~info javadoctags[23:51:53] <javabot> javadoctags was added by: blahjake on 02-26-2009 at 5:52 PM, EST and has a literal value of: http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/javadoc.html#javadoctags[23:51:53] <AMcBain> isr`: I gave you a link to a post with a "better" idea.[23:52:01] <milligan_> red-lichtie_, I haven't added action listeners to anything[23:52:04] <cheeser> ~tags[23:52:04] <javabot> cheeser, javadoctags is http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/javadoc.html#javadoctags[23:52:05] <isr`> oh really, i ddint see it sorry i was out getting food[23:52:06] * cheeser nods.[23:52:13] <isr`> you can pm it to me if you'd like[23:52:16] <cheeser> whew. read that wrong. i thought <see> was broken[23:52:37] <AMcBain> isr`: http://pastebin.stonekeep.com/5686[23:52:49] *** adi112358 has quit IRC[23:52:50] <tds5016> okay, I switched to prepared statements.[23:52:57] *** adi112358 has joined ##java[23:53:03] <tds5016> the strings still aren't escaping with slashes where it needs to.[23:53:40] <yobo2> tds5016: you're using setString() to set the string values right?[23:53:41] <red-lichtie_> How do I add a link to the javabot ?[23:53:46] *** Therx has joined ##java[23:53:50] <tds5016> yobo2: yes.[23:54:05] <tds5016> but any time I put in a ' it breaks.[23:54:13] <tds5016> and tells me I have a syntax error in my sql.[23:54:18] <yobo2> tds5016: what jdbc driver are you using?[23:54:25] <tds5016> connector/j[23:54:41] <EdwardIII> i guess if my app starts to look like a compendium of available errors it's time to use more try/catch?[23:54:44] <blahjake> red-lichtie_: a link in a factoid?[23:54:49] <isr`> AMcBain: wow that works a lot better, i'll have to investigate it further[23:54:58] <AMcBain> okay, good luck[23:55:07] *** Bonix has joined ##java[23:55:17] <red-lichtie_> blahjake: Yes, I want to link JMenuBar to http://www.exampledepot.com/egs/javax.swing/Menu.html[23:55:42] <blahjake> then do as i just did[23:55:43] <tds5016> yobo2: connector/j sorry if you missed it before, I forgot to add your name.[23:55:51] *** Ivellina has quit IRC[23:55:54] *** AlanasAnikonis has joined ##Java[23:55:54] <Therx> i'm applying a transformation matrix to a set of coordinates and wondered if there's a more efficient way using jogl than manually applying it to each[23:56:01] *** ScottG489 has joined ##java[23:56:18] <blahjake> ~JMenuBar[23:56:18] <javabot> blahjake, I have no idea what JMenuBar is.[23:56:39] <yobo2> tds5016: no i saw it... but i didn't see your original question, and i don't have much experience with connector/j. the driver is responsible for doing all that stuff but it seems weird it would have that bug.[23:57:09] <yobo2> are you positive that your sql is correct aside from the '?[23:57:35] *** Bollinger has quit IRC[23:57:54] *** GodTodd has quit IRC[23:57:57] <red-lichtie_> blahjake: Like what you just did ?[23:58:00] <tds5016> I didn't put the '?' in it. I assumed that would be done with setString[23:58:14] <tds5016> I just left it as ?[23:58:24] <blahjake> i added a factoid with a link less than ten minutes ago[23:58:33] <tds5016> should I have the 's surrounding the ??[23:58:36] <cheeser> no[23:58:52] <cheeser> ~~ tds5016 jdbc[23:58:53] <javabot> tds5016, jdbc is Java DataBase Connection, the standard java API for communicating with databases using embedded SQL commands. See http://java.sun.com/tutorial/jdbc[23:59:17] <red-lichtie_> javabot: JMenuBar is http://www.exampledepot.com/egs/javax.swing/Menu.html[23:59:17] <javabot> OK, red-lichtie_.[23:59:23] <tds5016> okay, then that should be correct.[23:59:27] <red-lichtie_> ~JMenuBar[23:59:28] <javabot> red-lichtie_, JMenuBar is http://www.exampledepot.com/egs/javax.swing/Menu.html[23:59:30] <yobo2> tds5016: no[23:59:34] <AMcBain> isr`: if it helps, the only reason I have to go all the way out to the JFrame is because Java's event system won't let me get the points in terms of the parent and when I tried to put the listener on the scrollpane, it didn't work[23:59:40] *** Level1_ has quit IRC[23:59:42] <yobo2> tds5016: just put a ?, the driver will quote the string as necessary[23:59:49] <red-lichtie_> Thanks blahjake[23:59:51] <yobo2> thats probably the issue