« first day (1630 days earlier)      last day (3312 days later) » 
00:00 - 14:0014:00 - 23:00

12:02 AM
I'm in dire need of my better half going to bed so that I can join in.
 
<-- feels jealous
 
fge
<-- wants to know whether mathematical studies have been kickstarted to quantify quantum decoherence
 
fge
1:13 AM
That's a good analogy: "electoral Schrödinger's cats, until a poll takes place which forces you to assume a choice [position]"
 
1:52 AM
hello~
 
hi
 
how's jooq master @fge?
 
He is great
 
2:22 AM
Morning, am I right in thinking that JFrame is like a built in super class. i.e.

public class MyClass extends JFrame{

means that MyClass inherits these built in attributes from JFrame?

Thank you
 
@mikeeustace If by "built-in" you mean ships with the standard SDK, yes. It's javax.swing.JFrame.
As for what inheritance implies in general, check out docs.oracle.com/javase/tutorial/java/IandI/subclasses.html.
 
Thanks @Jason C

Yep, that was my meaning of built in!
I understood inheritance as

...MySubClass extends MySuperClass...

Here, MySubClass will inherit (except for private) from MySuperClass. Is that the correct way of thinking of JFrame? It's a superclass.

Thanks
 
@mikeeustace Anything's a superclass if you extend it.
 
Thanks.
 
It's a superclass of your class; it doesn't usually make sense to just say "something is a superclass".
 
2:37 AM
Good Morning...
 
Morning.

Can you see why there's a "JLAbel cannot be resolved to a type" error?
My first GUI and I can't see where it's going wrong!

http://pastebin.com/6fhbvEpq
 
3:35 AM
@mikeeustace Hint: Are you sure it says "JLabel cannot be resolved to a type"?
 
Yep.
JLable cannot be resolved to a type
JLable cannot be resolved to a type

at jFrameNotMain.<init>(jFrameNotMain.java:9)
at GUIJFrame.main(GUIJFrame.java:7)
 
J - L - a - b - e - l ?
 
Ah, my typo
 
Heh
 
That second one is a copy/paste :)
Ah. Got it. :)
Had combinations of **el** and **le** throughout my code.

And I'm an English teacher lol
Thanks
Even the google result was trying to help me!

"Showing results for JLabel cannot be resolved to a type
Search instead for JLable cannot be resolved to a type"
 
3:43 AM
@mikeeustace Haha
 
4:24 AM
Hello!
 
 
1 hour later…
5:48 AM
Morning
 
HI all, i can't able to retrieve the form values in my servlet
 
but the logic works between jsp files
need ur help java geeks
 
I am not a java geek
 
Hi! I was just going through this question: stackoverflow.com/questions/5673260/…, but I cant seem to figure out what the myService object is from the second answer. Anyone?
 
5:58 AM
@shyam I estimate that its just a placeholder for a library to load a file. since FileSystemResource takes a file or a string in the contructor
@shyam he just didnt want to determine some library for fiel loading i think ;o
 
Yes. But what library? Do you know what class that object should belong to?
@Juce?
Oh, is it a custom service layer object that retrieves the file?
 
@shyam i think it's meant like writing "foo" or "bar". you can just put in a normal file there
 
Alright! figured that one out! Thank you! @Juce
 
np ^^
 
I didn't look at the constructor definition! My bad! :)
 
6:10 AM
how do you check if the code you've written is java SE8 or SE7 compatible?
 
@cp101020304 Depends on the compiler level you have used to write the code.
Java is forward compatible i.e. all code written in 1.7 will work with 1.8
 
i just used eclipse
and i compiled it through there
 
@ItachiUchiha yeah but you have to care for old dependencies and for the new Java 8 warnings ;)
 
so is there any easy way to find out?
 
@Juce dependencies are always a PITA. Java 8 warnings can always be suppressed
@cp101020304 find out what?
 
6:16 AM
oh never mind, i missed the forward compatibility part
 
@ItachiUchiha what does PITA mean?
 
thanks @ItachiUchiha
 
!! urban pita
 
@ItachiUchiha [pita](http://pita.urbanup.com/635466) 1) Acronym for Pain In The Ass, a major annoyance.
2) Flat bread of Mediterranean origin, eaten as is or filled with small pieces of roasted meat, veggies, condiments, etc.
@ItachiUchiha [pita](http://pita.urbanup.com/635466) 1) Acronym for Pain In The Ass, a major annoyance.
2) Flat bread of Mediterranean origin, eaten as is or filled with small pieces of roasted meat, veggies, condiments, etc.
 
@ItachiUchiha btw sure you can suppress them. but if there are lots of projects in a jenkins or something and the builds fail with warnings you will be surprise xD jsut saying ^^
 
6:17 AM
Good morning, Java
 
@OlegKuznetsov how was the interview?
 
@CapricaSix ah ty ^^ the second one sounds tasty
lol wrong click XD just answered the bot :D
 
@ItachiUchiha Well, it was a bomb (I was too nervous, so I couldn't answer simple things). So, now I have topics to work on this weekend :)
 
topics?
 
@OlegKuznetsov why were you nervous?
 
6:23 AM
@DroidDev I'm still unexperienced at interviews
@ItachiUchiha Hard to remember right now (and I left a notebook with my notes about them at home). Mostly, basic things
 
@OlegKuznetsov Please don't limit yourself by saying that you are not experienced at things. As you gain experience(at interviews or at job), you'll be interviewed by more experienced persons next time over. What will you do then?
interview is not a thing about experience in my opinion
 
@DroidDev hooooo
 
@DroidDev It's still not the usual situation for me (for now)
 
@OlegKuznetsov Please keep in mind that person interviewing you is trying to find a reason to hire you. They are not sitting there and trying to find a reason not to hire you. Just be yourself. Recently, I had an interview in front of two guys and they had collective experience of 20 years. They asked me, what was your favorite subject in graduation. I answered, NONE. I was selected to work with them. Just be yourself.
@ItachiUchiha mooooo
 
@DroidDev I'll try better next time. And thanks :)
 
6:36 AM
@ItachiUchiha It's always September.
 
@OlegKuznetsov don't thank me before you clear an interview(ok, I was just kidding, that dialouge came to my mind I don't know how :P). But again, there's no need to be nervous. If you don't know something, don't attempt to answer. Tell them you don't know it. Mostly, people are looking for innovative powers rather than cramming powers. All the best :)
 
" Mostly, people are looking for innovative powers rather than cramming powers. "

^^ this

remember, they're going to be using your cover letter / CV so be ready to answer questions they might have based on that.

Another important bit of advice, if they ask you to sit down, say "No thank you"
 
@mikeeustace ... why?
 
Tell them "no one every moved forwards by sitting down".

Then hi-5 yourself / fist pump the air.

The job'll be yours!
 
@mikeeustace haha, once in a GD, I stood up, before giving my introduction. They told me fist to sit down and then start over
:P
 
6:40 AM
@mikeeustace O~o
 
:) the fist pump is important. Don't forget it!
 
@Unihedro regex help :P
 
@mikeeustace Honestly, I don't think that's the right way. If anyone tells me "No one every moved forwards by sitting down". I'll simply ask them, "How are you going to write programs for me? Are you going to stand for, like, 12-14 hours?"
 
Replace a sequence space-any sequence of characters-space with space
 
I was joking @DroidDev :)
 
6:42 AM
._.
 
... Whoa, university credits.
never heard of it, this is so fake
 
> You will earn 3 university credits if you pass all :P
 
Does sound a bit dodgy!
 
Until recently: Get elected President. Nuke everyone. — cpast yesterday
._.
 
@DroidDev Haha. Worldbuilding. xD
 
6:52 AM
@Unihedro that question title. '._.
 
fge
7:27 AM
Moo
 
Moo
 
how to pass input in enctype form
 
ya kant
 
8:26 AM
Are methods in Java public by default (as opposed to private or protected)? I think so, from what I've read. If I've understood correctly, why bother writing public?
 
@mikeeustace What's "by default"?
 
I have

public class Food {

void eat (){

System.out.println("This food is great");
 
That's package-private.
 
by not having public / private / protected, is it public?
 
no
 
8:28 AM
Oh, what is package-private? Can only be accessed within the package?
 
public > protected > package-private (no modifier) > private
 
Thanks. @Unihedro.
I hadn't even thought that different packages could (or would) access one another. And I had assumed that package was an IDE specific term anyway. I haven't got to that in my reading yet :)
 
fge
@LeeJeong I'm no master
THere are many things I don't master about JooQ
 
8:36 AM
hi all
is it possible that i can get an advice here ?
 
Oh?
 
fge
@KarelG not if you don't ask for it :p "Don't ask to ask, just ask"
 
i have to review other's project. The client wants to have something as conditional state.

Let's say, there are 4 states, which is a sequence: state1 -> state2 -> state3 -> ...
If you want to proceed to the next state, you have to meet multiple conditions.
a co-worker used a superclass and subclasses which is a mess
not sure if a state pattern would fit well
or is there a better pattern method ?
 
This sounds like a basic "Wizard"
maybe you can draw some inspiration from:
12
Q: Simple Java Wizard

ThisIsNoZakuWorking on a project, I encountered a need to create a wizard and when I ran into the need for a second, slightly different wizard, I generalized into these classes. I originally based it off of this tutorial and attempt to adhere to these design considerations: Allow traversing the pages in a...

 
hmm, but you cannot return to state1 from 2.
 
8:43 AM
ohhhh it's borked...
> Guys, thank you for your answers! God bless you in Jesus name! Amen!
 
wow, i don't have an edit possibility ( lel, it's probably temporal)
 
@KarelG in that wizard? well that's a configuration thing..
 
i mean *you may not return
true
 
9:25 AM
Hey, I got a problem with JSF convertDateTime
I have this in my html page
<h:outputText value="#{message.timestamp}">
<f:convertDateTime pattern="dd/MM/yyyy" />
</h:outputText>
and message.timestamp is a java.util.Date format, but it doens't get formatted the way it should. The output I get is: Fri Apr 10 10:45:17 CEST 2015
and in my web.xml I have the following:
<context-param>
<param-name>javax.faces.DATETIMECONVERTER_DEFAULT_TIMEZONE_IS_SYSTEM_TIMEZONE</param-name>
<param-value>true</param-value>
</context-param>
 
@Erates try lowercase m
also fix your indentation please ;)
 
lowercase m doesn't work.. but I think I found the problem..
I got an entity Message, and a dto DtoMessage
while Message.getTimestamp() returns java.util.Date, DtoMessage.getTimestamp() returns a simple String
could that be the problem? That I use a String instead of a java.util.Date?
 
Hi
any one have restful api with PATCH method experience?
 
hmmm, that wasn't the problem
 
@Erates
 
9:36 AM
@PankajAndroid yes?
 
have u ever trie patch method?
 
@PankajAndroid Nope, I haven't, but just ask the question. If somebody with experience and a good will is present, he will answer
(or she)
 
9:47 AM
!!>eval([5, "+", 4].reverse())
 
@Unihedro [4,"+",5]
 
!!>eval([5, "+", 4].reverse().join())
 
@Unihedro "SyntaxError: expected expression, got ','"
 
wonderful. you are talking about error without posting it. — nikis 19 secs ago
include error messages!!!
usually they are helpful
also you definitely need to work on your orthography
 
!!>Number(undefined)
 
9:54 AM
@Unihedro "NaN"
 
!!>Number(undefined)||0
 
@Unihedro 0
 
\o/
 
10:06 AM
did you got caprica control tool for playing with her here ?
(i'm from js room, but i'm here for that advise)
 
fge
!!> NaN == NaN
 
@fge false
 
fge
!!>NaN === NaN
 
@fge false
 
!!> isNaN(NaN)
 
10:10 AM
@Unihedro true
 
!!>+(undefined)
 
@Unihedro "NaN"
 
!!tell Uni sandbox
 
@Uni Please go and play in the Sandbox
 
=javadoc Arrays#max
 
10:15 AM
@Unihedro Sorry, I can't find that method. :(
 
=javadoc Collections#max
 
Which one do you mean? (type the number)
1. java.util.Collections#max(Collection)
2. java.util.Collections#max(Collection, Comparator)
 
1
 
@Unihedro Object max(Collection coll): Returns the maximum element of the given collection, according to the natural ordering of its elements. All elements in the collection must implement the Comparable interface. Furthermore, all elements in the collection must be mutually comparable (that is, e1.compareTo(e2) must not throw a ClassCastException for any elements ...
e1 and e2 in the collection). (1/2)
 
10:27 AM
i want to upload a file along with some text inputs, since i am using ENCTYPE="multipart/form-data" i cannot able to send text inputs to the servlet.
how to solve this issue any ideas please
 
@greenhorn that's a misconception
 
interface IFoo {
    String getState();
    @Override
    public String toString() {
        return getState(); // not possible - wtf ?
    }
}
 
@Vogel612 how to do this logic?
 
... the answer of caprica to !!urban lol is quite unexpected ^^
 
@greenhorn Do you know what enctype means?
 
10:34 AM
@Juce caprica is looking up to the urban's site with the keyword. The site will reply what it can find with that keyword
 
@SecondRikudo it encodes the form data
 
@KarelG Interface methods cannot have state
@greenhorn Enctype determines the Content-type header (and the way you format your form) in the HTTP request you send to the server.
 
ah yes, while abstract classes do
 
@KarelG yeah i know ^^ but i would've bet on "laughing out loud"
 
The normal behavior is x-www-form-urlencoded
Which encodes everything as key=value&key2=value&...
 
10:37 AM
@SecondRikudo can you please tell how to do that job which i said
 
multipart/form-data is basically just another format
I don't know how Java servlets handle it
But be certain that they can.
 
@SecondRikudo so no idea of it right
 
!!>var foo={}, bar={}; foo==bar
 
@Unihedro false
 
@Unihedro as long as you don't have undefineds in your array:
!!> var foo = {a: "foo", b: 42, c: null}, bar = {a: "foo", b: 42, c: null}; JSON.stringify(foo) === JSON.stringify(bar);
 
10:45 AM
@SecondRikudo I'm learning to build a FSM model in JS.
 
@SecondRikudo true
 
@Unihedro FSM?
 
finite state machine
so I have objects to push into a stack and then check with equality.
Actually, I have the nested parenthesis problem, only now we have square, round and curly braces. :P
!!> [].isEmpty()
 
@Unihedro "TypeError: [].isEmpty is not a function"
 
!!> [].length === 0
 
10:49 AM
@Unihedro true
 
!!> [].size()
 
@KarelG "TypeError: [].size is not a function"
 
ah yes, it's a jQuery method
 
!!>Array("hello")
 
@Unihedro ["hello"]
 
10:53 AM
!!>Array.slice("hello")
 
@Unihedro ["h","e","l","l","o"]
 
!!>[].pop()
 
@Unihedro "undefined"
 
!!> "hello world".split()
 
@KarelG ["hello world"]
 
10:56 AM
!!>var mock = {push:()=>{}}; mock.push(".")
 
@Unihedro "undefined"
 
!!>var mock = {push:()=>{}}; mock.push("."); mock
 
@Unihedro {"push":"()=>{}"}
 
!!>var mock = {push:function(){}}; mock.push("."); mock
 
@Unihedro {"push":"function (){\n\"use strict\";\n}"}
 
11:19 AM
anyone here who loves python??
 
@Sword Everyone hates python.
 
kidding, will capricaa six be available in other chatrooms as well?
or only pre defined ones?
 
4 messages moved to bin
Not usually.
 
i don't like snakes either
 
11:36 AM
@KarelG Maybe it isn't a snake after all..
 
i know that py is a programming language
i've used it before for a datamining project of a client. Had to learn it because i didn't have experience with that
 
It is awesome..
 
you cannot master all languages
 
Good python code reads like pseudocode. You can say that it makes them comprehensible, but that's actually bad to define conventions. And limiting scope by indentation is the worst idea ever.
@KarelG You cannot learn all languages. do you even know how many there are, and continuously growing?
 
@Unihedro true.
 
11:40 AM
A good teacher once told me, that a good programmer knows all languages (even ones that they don't already study, for some sorcery reason). I proved them wrong. :p
 
hah, but you can group most languages since its syntax may be similar
 
Well, look at LOLCODE then.
Even its control statements work differently.
LOLCODE is an esoteric programming language inspired by lolspeak, the language expressed in examples of the lolcat Internet meme. The language was created in 2007 by Adam Lindsay, researcher at the Computing Department of Lancaster University. The language is not clearly defined in terms of operator priorities and correct syntax, but several functioning interpreters and compilers already exist. One interpretation of the language has been proven Turing-complete. == Language structure and examples == LOLCODE's keywords are drawn from the heavily compressed (shortened) patois of the lolcat Internet...
 
the name can say enough... "esoteric" :p
 
Then there's ><>. It was once my favourite, but I never had time to play with it.
 
@Unihedro actually there's some questions over at CR
 
11:42 AM
@Vogel612 not saying it's bad
or obscure, just that it's different
 
i remember someone whom came up with a language based on regex
 
@KarelG that's called Perl
 
@Vogel612 That's PCRE.
Perl 5.2 regexes are a nightmare.
v
\:2(?v
     >1n;
>:>1-::{*v
n*^!?(2@ <;
^^ here's how a factorial program looks like in ><>.
 
@Unihedro 99-bottles-of-beer.net/language-perl-737.html look at this ^^ it prints the whole song
 
@Juce That's not Perl 5.2...
 
11:49 AM
@Unihedro but it's regex ;3
 
Actually, I've seen it already, but nice. :p
Have you seen <Solve a maze with .NET regex>?
 
nope
 
(Now playing: Janji - Horizon)
 
Can this question be considered as off topic on SO?
 
███████████████████████████S█████████████
█         █ █           █ █   █     █   █
█ ███ ███ █ █ ███████ █ █ ███ █ ███ ███ █
█ █ █ █     █ █   █   █ █   █   █ █ █   █
█ █ █ █████ █ █ ███ ███ ███ █████ █ █ ███
█ █ █     █ █   █   █   █     █ █   █   █
█ █ █████ █████ █ █████ █ ███ █ █ █████ █
█ █     █     █ █     █   █   █ █       █
█ █████ █████ █ █████ █████ ███ ███████ █
█       █   █ █   █ █ █           █   █ █
█████ ███ █ █ ███ █ █ █████████ ███ █ █ █
█ █   █   █     █   █     █     █   █   █
@ItachiUchiha It's on topic if it's a real problem. It's not if it can't be reproduced.
It involves tools directly used for programming, so.
 
11:52 AM
But, he says it works perfectly on another environment.
 
... It depends on whether it's a real problem, or if they're lying.
 
hmm, directly used tools for programming makes it on topic
TY ^_^
 
"how to turn off youtube" is OT, "how to turn off IntelliJ IDEA" is in scope.
 
@Unihedro this doesn't seem to be solvable
 
:22607115 ███████████████████████████↓█████████████
█         █ █↓<<<<<<<<  █ █>>↓█>>>>↓█   █
█ ███ ███ █ █↓███████↑█ █ ███↓█↑███↓███ █
█ █ █ █     █↓█   █>>↑█ █   █>>↑█ █↓█   █
█ █ █ █████ █↓█ ███↑███ ███ █████ █↓█ ███
█ █ █     █ █>>↓█>>↑█   █     █ █↓<<█   █
█ █ █████ █████↓█↑█████ █ ███ █ █↓█████ █
█ █     █     █↓█↑<<<<█   █   █ █>>>>>>↓█
█ █████ █████ █↓█████↑█████ ███ ███████↓█
█       █   █ █>>↓█ █↑█           █↓<<█↓█
█████ ███ █ █ ███↓█ █↑█████████ ███↓█↑█↓█
█ █   █   █     █>>↓█↑<<<<█     █↓<<█↑<<█
This replacement that solves the maze is done with a regex.
 
fge
11:54 AM
Oh dear
Where is "use the right tool for the job"?
 
In hell, weeping for the lost souls.
 
fge
Well, OK, someone did program Quake on an oscilloscope
 
Optimize str = str.trim().replaceAll("\\s+", ":").replaceAll(":+", ":");
 
@ItachiUchiha turn it into a proper parsing function and get rid of regexes
 
11:57 AM
Naah, let me define the problem statement.
 
@fge stop... wait what????
 
@Vogel612 You didn't know?
 
nope...
 
I have a String "2013_07_18 : abc 30" which I want to reduce to 2013_07_18:abc:30. The problem is between abc and 30 there is some special character which is taken care by \\s+. But it gives me a result of 2013_07_18:::abc:30 and I have to use another replaceAll which is sad.
 
12:00 PM
3 mins ago, by Unihedro
@ItachiUchiha turn it into a proper parsing function and get rid of regexes
 
Errgh, I need to improve my optimization skills.
 
No, your algorithm is bad.
And you should feel bad parse the string instead.
 
^^ true that
 
I thought my algo is bad so I took a second opinion here :P
 
fge
12:16 PM
@ItachiUchiha .replaceAll("\\s*(:\\s*)*", ":")
Hmm, replace the first * with a + actually
 
Replace the asterisk at the end with +
and (: -> (?::, optionally
 
how stable is the string format? regex approach is rather fragile so if the string format has any flexibility it may be better to go with Uni's suggestion to use a real parser
 
:)
 
12:36 PM
is it possible to use savepoints between two servlets
 
yes
 
how buddy
 
can google not help you ?
 
12:56 PM
@KarelG hmm gud
 
Hi everyone...
I want to create two open two session factory just like following
serverSession = ServerHibernateUtil.getSessionFactory()
.openSession();
clientSession = ClientHibernateUtil.getSessionFactory()
.openSession();
Is it possible ?
 
In Hibernate? I don't think so
 
1:17 PM
@Gops Yes it is possible, do you have multiple data sources?
 
@LuisAverhoff heya
 
Hello Everyone
 
Hello
 
the comment section was getting too long to discuss ;)
 
hey
ya
 
1:19 PM
so what did you try?
 
I tried the example that you left getClass().getResource("/millionairetriviagame/AudioFiles/GameIntroTheme.mp3");‌ and then i got illegal character escape(\u200c) and that uri can't be converted to string.
 
did you add toExternalForm() at the end?
 
yes
still illegal character
thats the problem
 
that's strange
 
yes it is
 
1:22 PM
Can you try the example which I linked in one of the comments??
just paste it in the same package millionairetriviagame and change the path to the mp3
 
actually it wasn't a illegal character escape just illegal charcter
 
@LuisAverhoff Why / at the start? Your millionairetrivialgame directory is located at the origin?
 
@Mr.777 No, I don't have data source I am using one MySQL and different db
 
Yes I took that / out from the beginning and I'm still getting illegal character
That is rich if I take out the entire path I still get illegal character
great
 
That doesn't answer my question at all. Where is your directory located?
 
1:30 PM
Oh take a look at this question. It has my directory in the main post stackoverflow.com/questions/29551281/…
 
That's Windows.
It's also only the project directory, not your environment directory. To begin with, it doesn't say where the built jar is.
 
Ok I guess I can paste where the jar file is exceuted everytime I exceute the program if that helps
 
... Just answer the question, it's a simple one.
 
Check the string you use. The character 200c
That's not something you normally have in file names
 
Well your question is Your millionairetrivialgame directory is located at the origin right? Well anything millionairetriviaGame is located in the source packages. If that is not wasn't your question is asking then I'm sorry I have no clue how to properly answer it.
 
1:41 PM
@LuisAverhoff there is no problem with / in the beginning. My wild guess would be some unwanted character is spoiling the path..
 
I don't know, it was working well a minute ago and now this started happening
 
with the guess being 200c, which happens to be the character you get an exception for, and also happens to be an invisible control character
 
even if I leave the code like Media gameIntroTheme = new Media(getClass().getResource("").toExternalForm());‌ I still get illegal character
\u200c is the illegal character
 
how did you create the empty string? by deleting the contents you had there before? that could leave in place whatever was there at the start or end of the old string
 
well the program doesn't mind if I leave like this Media gameIntroTheme = new Media("");
now it is not giving me that error anymore Media gameIntroTheme = new Media(getClass().getResource("millionairetriviagame/AudioFiles/GameIntroTheme.MP‌​3").toExternalForm());
though now I'm back to where I was at. it's stilling giving me nullpointerexception
 
1:51 PM
resources are loaded relative to the class loader, unless you specify the absolute path. it's really rare to not need to start with "/"
 
If you are using the package name you ought to start with /
 
that still doesn't work :/
 
Try re-typing it
 
alright
 
I have issues with that my letters are being changed sometimes, retyping it normally solves it
 
1:56 PM
depending on what "does not work" meant this time
in case of illegal character retyping is the right thing to do
 
^^ true that. But make sure you delete everything
 
don't worry the illegal character is gone. it's just the path is returning null
 
00:00 - 14:0014:00 - 23:00

« first day (1630 days earlier)      last day (3312 days later) »