« first day (1560 days earlier)      last day (3372 days later) » 

10:00 AM
I feel that recruiting the most active user to the site (who is now one of the mods) was a good contribution as well :-)
 
And they say we don't have fun at SE.
@Mourdos Pro tem moderation?
 
Yeah. Though I suspect he will be a moderator in the long run as well. All three of our moderators do a very good job and we don't have any contention within the community.
 
@Vogel612 Still hanging in?
 
About the only thing that tends to gets disagreed on is how broad a question needs to be before it is too broad, but we will always have that given the nature of the site.
 
@Mourdos Pro tempore moderators are picked so the community can save itself from problematic situations before the high rep users have the power required to spin the wheel. Once the site graduates and builds a stable community to run an election, pro tem moderators graduate with the site as well. They are however welcome to participate in the election and attempt to become an elected moderator then.
 
10:03 AM
I realise. I suspect that all three will be voted back in.
 
user4202350
@Unihedro My vote goes to Unihedro, Make him Moderator.
 
@ItachiUchiha kinda...
 
@Mourdos Probably. Oh well, only time can tell.
<- not a worldbuilder
 
oh look: this exists!
 
@Gemtastic Stack Exchange has all the answers!
 
10:07 AM
Indeed
 
@Gemtastic don't go there,,,,
It's a terrible place
 
@Vogel612 not really
The mods are terrible. The content are generally helpful, and the users are generally helpful, as long as you don't come across a moderator.
 
It's Android..
 
Hey, Android is built on Java bytecodes.
 
well I might be kinda biased since I only get there via the tavern...
not everything coming from java is good..
 
10:09 AM
ಠ_ಠ
 
@ItachiUchiha you said you wanted some code reviewed??
 
@Vogel612 It's not totally Java. Also, You should see what Android is capable of before saying such words. :)
 
I have seen android code
 
Also I would be interested in knowing that what makes you think so ?
 
I have seen android "architecture"
and It's crap
 
10:12 AM
What crap you're talking about ?
 
It's completely retarded to force the user to setup a view from one entry point
that's always the same
and not even static
 
fge
Moo
 
Mooning
 
Moonking
 
The documentation over at android docs is at best mediocre
 
10:13 AM
@Vogel612 Yeah, because Google wrote them.
And Google really sucks.
 
... at writing documentation
Programmers are extremely limited in what they are allowed to do.
 
fge
I agree, I had the devil's job getting started on the Google Drive filesystem
 
@Vogel612 yes
I have a class called DBConnection, which has a method fetchConnection()
 
Well, once we're done with the databases and writing pretty code we're gonna hit android. So I kinda have to go there.
 
poor you @Gemtastic
 
10:16 AM
shurgs It's good to know, though I will probably got into JavaEE stuff
 
@ItachiUchiha this sounds wrong..
 
I wrote one android application, except I did it via CoronaSDK so it also built for iPhone.
 
I catches all the exception in the same method including ClassNotFoundException, SQLException etc
logs it and returns null
 
@Gemtastic NDK-plz
 
so far so good..
 
10:17 AM
@Vogel612 what is wrong in it already?
 
Or at least, don't rely on the ragged classes in the SDK, just use the OpenGL component
 
@Unihedro NDK?
 
usually I wouldn't expect a DBConnection to fetch a Connection
 
@Vogel612 ahh..
 
rather I'd expect DBConnection::connect
 
10:18 AM
so method is public Connection fetchUserConnection()
 
why would you expose the connection?
 
^^ Don't you think that catching the exception in this method is incorrect ?
 
:21256684 I don't get why you're asking me for it with the "NDK-plz"
 
@Gemtastic use Android NDK, not SDK :p
 
10:19 AM
@Vogel612 This method creates a connection for other service classes to use
 
It should be fine
 
@Unihedro Well I figured that was a must?
 
but maybe I would throw a bundled exception instead of returning null..
 
@Gemtastic idk you'll see
When your class gets to that part.
 
Well, we'll see when we get there. First; databases and pretty code
 
10:21 AM
No unit testing?
 
I'm not sure what the "pretty code" means but meh shrugs
 
@Vogel612 I think all these exceptions should be catch'd in the calling method, because returning null will result again in NullPointerException in the service class
 
pretty please :-) I think it means surrounded in code tags when you post it here.
 
@Unihedro Unit testing is a part of this course too actually
 
@Gemtastic Hooray!
 
10:21 AM
@Unihedro So I'm gonna read that book fge recommended you :)
 
Bah, unit testing. The thing every system needs and almost nobody wants to write.
 
@ItachiUchiha you could throw a new exception instead of bubbling the others
 
in Teenage Programmers Chatroom, Jan 18 at 20:18, by Unihedro
Unit testing is like flossing - everyone agrees it's good, no one really does it
Flossing is good for you.
 
@Mourdos Theoretically I won't mind. My current code is already centered around double-cheking that the code does what I intended it to do.
But I suppose I won't know if I like it or not until I've learned it
 
10:23 AM
@Vogel612 why a new exception?
 
public Connection fetchUserConnection() throws SpecializedDatabaseException{
     try {
           Connection connection = new Connection(credentials);
           return connection;
     } catch (Exception ex) {
           //LOGGING HERE
           throw new SpecializedDatabaseException(ex);
     }
}
 
The thing about unit tests are that they are automated - By using automated tests, you prevent mistakes made in the manual testing process that 1. wastes your time 2. hides bugs that makes you think it's OK 3. miss edge cases
 
@ItachiUchiha you make it easier for calling code to be prepared for it
 
I think the worse case of exception handing I've seen is in a system that used reflection to call almost everything. That and ajax calls for fast page loading. Except that one page used about 40 of them and the system was set up in such a way that for the java server to reflect to itself, it had to get down to the network layer before it realised where the server it wanted to talk to was.
And each of the calls could spawn multiple calls via reflection, and did.
 
why would one do such a thing?
calling stuff with reflection is a royal PITA
 
10:25 AM
So your exception got hidden many reflected calls down.
 
@Mourdos That's a nightmare, I would be in overrage if I have to maintain a project like that
Using reflection in a broken way, that is.
 
This question is on the very edge of being primarily opinion based. I am not voting to close but I am downvoting because of the way the question is formulated. — Simon André Forsberg Dec 26 '13 at 19:21
 
I left the company in November, 9 months after we got the product.
A 'Software house' in France put it together. All their senior developers left after the prototype was created, so they effectively rotated junior developers through the 7 year project every 6 months.
 
@ItachiUchiha check the second answer.. Null Object Pattern
sounds like a good idea here.
 
10:26 AM
@Mourdos Ha!
gg no re
 
They made over a thousand calls to acquire service providers in the code. They put about 500 back.
There was code that didn't work, but looked like it worked. So we ended up copying it when we needed to add new features and modifying it, only to find our code didn't work.
 
@Mourdos Duplicating code?
 
My favourite bug was that they made the Customer object a singleton. Race conditions anyone?
 
This story is madness.
 
This is the story of how two major car manufacturers had their dealer and finance systems replaced by madness.
 
10:29 AM
Singleton customer.. sounds like a bad business model :')
 
@Mourdos: Were there really no coding standards? Sounds like microsoft-style programming, except far worse.
 
Lets put it this way. The company I worked for took the project off the original company
 
This original company must really suck then. :P
 
We had two java developers (one was a contractor). By the time I left there were two permamant java programmers and 10+ contractors
using angular js
Yeah, its a rolling train wreck, they are currently re-developing the frontend pretty much from scratch.
 
Just the front end?
 
10:33 AM
@Vogel612 Null Object Pattern is an overkill in my case. I guess, I will leave it with returning null and just add a null check in my service class
 
user4202350
How to write in italic [i]Italics[/i]
 
@ShaU *italic*
 
Did I mention that the database is over 12 years old and Sybase, and everything is abbreviated french?
 
@Mourdos Hey, reminds me of:
 
user4202350
[italic]Hey[italic]
 
I left the company because while I enjoy finding and fixing bugs (I'm good at tracking them down), I had written less than 20 lines of code in over two weeks.
 
They should get in touch with the author of the above article, they will fall in love and should get married.
 
And that was a regular state of affairs. As well as having me deal with document templates.
 
@Unihedro lolz. Our hate lives :P
 
I'm a programmer Jim, not an analyst
 
10:36 AM
^^ Well said
 
The guy in charge of deployment and code management didn't like branches
 
@Mourdos stab him
 
He was also in charge of batches, written in a legacy language about three people in the world use.
 
user4202350
[italic]Hey[/italic]
 
@ShaU Write this: *Hey* with the asterisks.
 
10:38 AM
@Mourdos Mark him down, Kill him. This is a rebellion
 
Ah, here is another for you. They had a hibernate query that returned 20 rows. It was a common call and they had about five or so methods call it, so they would use setters for the objects they were creating.
obj.setName(result[1])
obj.setValue(result3]) etc
Which would have been good
 
This is not a forum, we don't run bbcodes (which are stupid and never parses correctly).
 
it gets worse
They had:
final static private String ZERO = new Integer(0);
 
user4202350
[italic]*Hey*[/italic]
 
@Mourdos Microsoft style coding confirmed.
I don't think it even compiles.
 
fge
10:39 AM
@Mourdos that does not compile
Not in Java at least
 
String ZERO = new Integer (0);
 
@fge Beat you to it. :P
 
Sorry, it was int
I'm doing it off the top of my head
 
At least Integer.valueOf(0) would had been more sane.
 
yeah
 
10:40 AM
final static private int UN = new Integer(1);
final static private int DEUX = new Integer(0);
So we actually had:
obj.setName(result[UN]);
obj.setValue(result[TRIOS]);
 
5 mins ago, by Unihedro
They should get in touch with the author of the above article, they will fall in love and should get married.
 
Which went up to 20
and there was no 18
 
lolz
 
Which meant, since I don't know french, that I had to tooltip them all the time.
 
@Mourdos I quote from ~unmaintain:
> Mix Languages

Randomly intersperse two languages (human or computer). If your boss insists you use his language, tell him you can organise your thoughts better in your own language, or, if that does not work, allege linguistic discrimination and threaten to sue your employers for a vast sum.

Names From Other Languages

Use foreign language dictionaries as a source for variable names. For example, use the German punkt for point. Maintenance coders, without your firm grasp of German, will enjoy the multicultural experience of deciphering the meaning.
 
10:43 AM
Lets see, another favorite was...

String aNumber = "-1";
...
//bNumber is an actual number Object
if (aNumber == bNumber)
What else was there...
 
LOL, with that kind of coding quality you'd be incredible to get something that compiles and runs properly
 
methods were commonly over 1000 lines long?
 
wannabe coders ho
 
Hmm. lets see, what else...
Nope, my Skype log of horrors to a friend doesn't go back that far
The stored procedures in the database were in a similar state.
And all of them had subprocs
all of them
I feel like a proper programmer again, I have two widescreen monitors (but still a laptop as the base machine...)
 
Morning people
 
10:53 AM
Morning
 
Mrng
 
morning
 
user4202350
morning
 
@PeeHaa hiya
 
11:10 AM
@Unihedro Why is spring so terrible?
 
@Mourdos ikr?
 
I've just been looking at that starred message and wondering why.
No, as in, I actually don't know.
Can you tell me?
I've had some experience with Spring and it was pleasant enough.
Though of course I could be mistaking what was spring and what wasn't.
 
Oh god the java room is drunk again :P
 
I believe there is a room for trying out text stuff.
 
@Mourdos /1
 
11:12 AM
7 messages moved to Sandbox
 
@PeeHaa Why do you say that?
 
1 min ago, by Unihedro
7 messages moved to Sandbox
 
Ah, no, that is mostly just Shau's text being thrown out.
 
@PeeHaa Still, that's not the whole room, just a user.
 
Well to be fair. You are all developing in java so you all most be drunk :P
 
11:14 AM
Heh.
 
I think that of PHP and javascript devs
 
Thank you thank you I will be here all night
Clearly PHP is superior to java in every way
And javascript is just java with script appended to it
 
Well to be fair, the fact that there are more bad devs from the Java lane is realistically true and is why I laugh at names of wannabe coders.
 
/troll
 
@PeeHaa PHP sucks.
 
11:16 AM
Whenever someone says they are a PHP developers, I automatically assume that they are self taught and have no idea how to put together maintainable code until I see otherwise. Sadly that has been my experiance.
 
@Unihedro Yeap
 
The founder can't even decide whether to stick with snake casing or camel casing. And it's such a weak language that does everything in one line in such poor ways!
And what, regex?
 
@Unihedro We are talking about rasmus?
 
It says something that my boss is a PHP developer, right?
So yes, is there a concise list of reasons about what it wrong with Spring? Or should I take all the "everything is on fire" with a large pinch of salt?
 
11:20 AM
@GurumoorthyArumugam Yo
 
how to convert byte[] to string
 
@GurumoorthyArumugam hey
 
@GurumoorthyArumugam one does not simply convert A to B where A does not equals B.
 
So this doesn't answer it: stackoverflow.com/questions/8654141/…?
 
@Mourdos That's fundamentally different?
 
11:22 AM
Oh, byte[]
I see
 
@GurumoorthyArumugam Try this, and tell me if it's as of expected behaviour:
 
user4202350
to do tricks
 
byte[] bytes;
String str = Arrays.toString(bytes);
 
i tried String s = new String(bytes);
not getting
@Mourdos its not byte its byte[]
 
@GurumoorthyArumugam That's encoding dependant, environment dependant, and only transfers an encoded byte array (from a serialize dump) into a raw string. So unless you did exactly that (which is unlikely otherwise you would had known what to do), that's not the right way.
 
11:26 AM
what i'm trying to do is

i'm creating a SecretKey like blow

SecretKey secretKey = keyGen.generateKey();
byte[] encoded = secretKey.getEncoded();
System.out.println("key: "+encoded);
problem is i have to pass this key to server team via URL
 
4 mins ago, by Unihedro
byte[] bytes;
String str = Arrays.toString(bytes);
Or:
Arrays.stream(bytes).collect(Collectors.joining("+"));
 
@Unihedro this one returning like this pastie.org/9873646
 
@GurumoorthyArumugam Good, so it works.
Bye for now, then.
 
fge
11:51 AM
Creating my first spliterator
Not very easy
 
:p
 
fge
12:08 PM
Ohwell, it wasn't that hard after all
 
Just not very easy :P
 
fge
gist.github.com/fge/74c557f162ef0c2aaf8e <-- that's the Spliterator
Not parallel at all for the moment but it may be...
 
Hi everybody. Anyone knows a program to do regex by input?
 
fge
@Goldbones define "by input"
 
12:24 PM
@OlegKuznetsov thanks. That´s it
 
@OlegKuznetsov That site sucks.
 
Really. What´s the best?
 
Wait, confused it with another thing. Never mind me.
 
@Goldbones That's my favourite shrugs
 
and it has a lot of examples which is great
 
12:44 PM
@Goldbones A lot of them are suboptimal, so take it with a grain of salt.
 
fge
<-- loves his BackgroundTaskRunner
 
At my regex skills they are very optimal
 
@Goldbones Well just because you're new to writing regular expressions doesn't mean you don't deserve one that runs faster when used in code.
Especially when you throw in one in a programming contest, where performance can change your life.
 
^([123]0|[012][1-9]|31)-(0[1-9]|1[012])-(19[0-9]{2}|2[0-9]{3}) ([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9]),([123]0|[012][1-9]|31)-(0[1-9]|1[01‌​2])-(19[0-9]{2}|2[0-9]{3}) ([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])$ for dd:mm:yyyy hh:mm:ss, dd:mm:yyyy hh:mm:ss is good?
 
fge
Eh?
Why don't you use a date parser?
 
12:51 PM
This is one of those cases where you should parse, and not with a regex.
 
Really? I thought that regex was allways faster
 
@Goldbones hahaha, no
Regex is almost always slower.
 
why?
 
For general case parsing algorithm N and regex N(general), parsing uses resources of min(general), where regex uses N(N) resources used to run the finite state engine.
And for optimal case parsing algorithm X and regex X(optimal), regex is only slightly less resource consuming, while a parser is generally faster than using regexes when comparing optimal parsers and regexes.
@Goldbones Because regular expressions runs in a regex engine.
 
now makes logic
 
1:00 PM
Not like I'm muttering nonsence.
Actually, I probably am muttering nonsense.
Well, let me demonstrate this to you. For example, given you have a string, what would you do to parse it, and what is the regex you would use, to check if anywhere within it has the character sequence "10"?
 
1:31 PM
"Their code is so messy" -> I'm led to believe that it is you who have insufficient OOP experience to comprehend simple code instead, as most projects follow simple standards such as SOLID (especially WorldEdit and VoxelSniper - in fact, sk89q built WorldEdit with exemplary tests & documentation, it has to be one of the most elegant projects). Additionally, it was documented in both the Bukkit wiki itself and the Minecraft wiki that the data value is stored as the damage value and not the NBT saved metadata, where did you spend your hours? — Unihedro just now
 
Is it a good practice to declare a class just for constants (public static final) ?
 
Well.. he's ust gonna go with the piece of code that he doesn't understand anyway
 
@Gemtastic Duh.
@ItachiUchiha No. Use an interface.
 
@Unihedro The funny thing is, that when you have the code you can so easily see what you can do with it >_>
 
Why am I participating on this site anyway? I really can invest on more productive things than chatting in like, over fifty rooms and maintaining quality.
 
Don
1:34 PM
hiii
 
But what's the fun in that? :)
@Don Hello!
 
Don
anybody help me?
 
no
 
Don
very urgent
 
user1907906
@Don d just ask
 
Don
1:36 PM
I need to add integer elements inside a list
 
Don
my list list=[5,4,3]
 
@Don Is that a list or an array?
And more importantly, is this even Java, or Javascript?
 
Don
list from server side
Its Java
Its a query result
 
That looks weird
 
Don
1:38 PM
I have selected some numbers from Database to list
 
@Gemtastic The pic or the (pseudo)code?
 
Don
return list = session.getcurrentsession.createQuery("").list;
 
> my list list=[5,4,3]
 
Don
sorry
return session.getcurrentsession.createQuery("").list;
And i got this list [5,4,3]
Now i want to add those elements inside the list
is it possible?
helloo???
 
@Don Wait, is your question really simply "is my task possible"?
 
Don
1:42 PM
Let me check @Unihedro
 
Yes of course - programming is about making impossible things posible. If a task requires knowledge you don't have, acquire it. If it requires code you can't access, use reflection. If it requires an interface you can't access, use native code. If it uses a technology you can't depend on, develop your own protocol. In the world of programming, everything is possible!
7
 
Don
:) @Unihedro
But i need some help @Unihedro
 
@Don I am aware. Can you describe your actual task?
 
user1907906
@Don Should be easy. Did you create a question?
 
Don
No i didnt
@Unihedro List<Object[]> list = EnquiryService.getQuantityById(60);
 
1:47 PM
> If it uses a technology you can't depend on, develop your own protocol.
 
Don
got a list like [5,4,3]
 
^^ too much
 
Don
Ohh sorry
 
@Unihedro I was thinking of it, thanks anyways
 
@ItachiUchiha Not enough awesomesauce? Seriously, since I'm not coding, I can rant more :)
in Alpha Centauri on The Stack Exchange Network Chat, 2 hours ago, by Unihedro
Today is not a very productive day - I'm not in mood to code for a weird reason, so I'm reading on interesting topics I never got the time to before, like structured unit tests. :p
 
fge
1:48 PM
@Unihedro not coding?
slap pam4j
 
@Unihedro oh, you're not coding?
 
@fge @Vogel612 yes, reading day
 
slap javabot 33 / pr #40
 
(Meanwhile, the world is shocked to hear Uni is not coding)
 
pr 40 is some reading
 
1:48 PM
@Vogel612 O, kk!
 
fge
And slap again, for good measure
 
Well now I have a full coding schedule again, thanks guys
You're the best friends ever :D
 
fge
Not that pam4j should be news to you :p
 
pam4j hooray
 
fge
I may very well get to it before you even get started, ya know
 
1:51 PM
lol :D
 
fge
But right now I'm fully committed to the debugger
 
Even I am not coding, reading a book on TDD :P
and some work(which I son;t have to do, but I have to do), which is wasting my time :P
 
fge
Oh? Is that the one I mentioned?
 
Nope
It is Test Driven Development By Example, by Kent Beck
I was not able to land my hands on the book you recommended
 
fge
Ah yeah, Kent Beck
I know the guy but I disagree with some of his beliefs
 
1:54 PM
He is a funny writer :P
 
fge
Tonight I won't be there... France/Spain
I want France to WIN
And be world champion for the 5th time
 

« first day (1560 days earlier)      last day (3372 days later) »