« first day (1591 days earlier)      last day (3333 days later) » 

fge
2:00 PM
No it's not; if it is to this degree then you have a design problem
(and more often than not this design problem stems from a lack of knowledge of the problem space and/or tools to deal with it)
 
i knew it had something wrong with it
thanks for the heads up
 
fge
Well then, what is the problem space?
(as an aside, modern JVMs are able to perform lock elision, but that's not the problem here)
 
i wouldnt call it a problem but when i looked on my program i saw synchronized anywhere and i wondered why i need all of those
@fge i have one more question i asked Unihedro yesterday and he didn't have time to answer me
can you see where im going with this pastebin.com/QNc8xY46 and is it good or bad
 
@dystroy NetBeans! NetBeans!
 
@OlegKuznetsov Why ?
 
2:06 PM
It's faster than Eclipse
 
fge
@somefolk I only need a cursory look to answer "bad"; you don't want to extend Thread
Not in 2015 and, in fact, not since Java 5 and the advent of java.util.concurrent
 
@fge i though to myself that it actually could save some code and have more functionality
 
fge
Just look at what java.util.concurrent has to offer
 
@somefolk Where's my air freshener?
 
checking it right away
 
fge
2:08 PM
Between executors, futures, etc..
 
@Michael pfft XD
 
fge
There is plenty of everything
 
@somefolk At first glance, you seem to be way overcomplicating things.
@fge What's the alternative to extending Thread? I do it all the time.
 
fge
@Michael using {Scheduled,}ExecutorServices
 
@Michael well, thats my native
 
fge
2:10 PM
Should that only be using an Executors.newFixedThreadPool(1)
 
@fge I'll have to check those out.
 
fge
=javadoc Executors
 
@fge java.util.concurrent.Executors: Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory, and Callable classes defined in this package. This class supports the following kinds of methods: Methods that create and return an ExecutorService set up with commonly useful configuration settings. Methods that create and return a ...
ScheduledExecutorService set up with commonly useful configuration settings. Methods that create and return a "wrapped" ExecutorService, that disables reconfiguration by making implementation-specific methods inaccessible. Methods that create and return a ThreadFactory that sets newly created threads to a known state. Methods that create and return a Callable out of other closure-like forms, so they can be used in execution methods requiring Callable.
 
fge
^^^^ that
And since you use Guava...
=javadoc MoreExecutors
 
@fge com.google.common.util.concurrent.MoreExecutors: Factory and utility methods for java.util.concurrent.Executor, ExecutorService, and ThreadFactory.
 
fge
2:11 PM
^^^^ that too
 
Ah, nice. Thanks. :)
 
fge
Also, an undocumented fact but very important...
Timer{,Task} is unreliable
 
best folks on @java
 
fge
The reason is a little tricky but it's due to the fact that scheduling relies on System.currentTimeMillis()...
... Which is unreliable, because it depends on the system clock, which can change (think NTP and winter/summer time)
Whereas ScheduledExecutorService relies on System.nanoTime() which is monotonic
(well, not by itself but all implementations in the JDK)
 
Interesting.
 
fge
2:15 PM
Come to think of it, it was one of the very first things I explained in this room
Note that this is also why you will preferrably use TimeUnit.WHATEVER.sleep() rather than Thread.sleep()
 
<-- Still thinking when did fge join this room
@fge and why is that?
 
@ItachiUchiha me too
 
@fge Because TimeUnit.WHATEVER.sleep() uses System.nanoTime()?
Anyway, gtg to work. Bye all.
 
@Michael first message in the chatroom :P
Oct 26 '10 at 2:16, by mangst
I just found out about these new chat rooms.
 
Please don't look mine up, it's a really stupid question.
That's not reverse psychology.
 
2:24 PM
You make me curious :P
 
This sentence, the above one and the one above the above one isn't reverse psychology either.
 
Jul 9 '14 at 2:43, by Unihedron
Greetings dear sirs, a quick question... What are the differences for catch(final ExceptiontoCatch ex) and catch(ExceptiontoCatch ex)?
 
fge
@Michael yes; more precisely, it uses the two-argument version of Thread.sleep()
 
^^ Is this it?
 
Ugh. xD
 
fge
2:27 PM
(although the javadoc does not mention it, this version appeared in 1.5; in 1.4 and lower you only had the one-argument version)
 
fge
Argh
Bad quote
 
@fge Please write a good one :P
 
fge
This was meant for @ItachiUchiha
Meh, is there really a need? :p
 
not really, but I will get to know what a good quote is :)
 
fge
2:30 PM
Uhwell, I only mistakenly quoted the wrong message; nothing really spectacular
I am still more used to (and prefer) IRC on the whole
 
Are there people on the IRC?
 
@ItachiUchiha Yes.
 
<--- Never used one
 
fge
Sure, a lot of them
 
Most channels are moderated, and the unmoderated channels really suck.
 
fge
2:32 PM
##java on FreeNode has real "monsters" in it
Among others, the authors of TestNG, JRebel and lombok
 
What's JRebel?
 
fge
@Unihedro a framework allowing for real time replacement of classes (bytecode wise) at runtime
 
> ##java Cannot join channel (+r) - you need to be identified with services
 
fge
It uses the same API as pitest does
@ItachiUchiha /msg NickServ help
 
@ItachiUchiha login duh
@fge ... Whoa.
 
fge
2:34 PM
@Unihedro yeah, as you say; I learned a lot about ASM from its author (Maldivia on ##java)
(real name Michael Larabel)
 
hello ppl hw I can flush out ObjectInputStream obj
 
fge
Such bytecode manipulations are waaay over my head
@SuroorAhmmad you don't flush input streams, it makes no sense
 
@fge I'm interested! I never even knew it was possible.
 
then way does cause EOFException
@fge I am continuously reading data from java server... if I close ObjectInputStream it cause socket close exception and if I dont it leads to EOFException
 
fge
@Unihedro then I suggest you have a look at the source code of pitest... Honestly I've never dug into it but I do know that they use the same API
As far as I'm concerned I have no interest in digging this far into the JVM at the moment
@SuroorAhmmad why use Serializable at all then? Try and use, uh, some portable, less broken format? Like, uh, JSON?
 
2:42 PM
I am sending screenshots from java server to another java program... so is there any other way?? @fge?
 
fge
Sure there are
 
can u pls suggest me bro!!
 
fge
But I have zero knowledge about image manipulation so that's about all I can say; that and avoid Serializable at all costs
@SuroorAhmmad just do a quick search on the net, you'll get a bazillion of results in no time
 
@SuroorAhmmad well that's not even a problem with the stream
you're using a stream where the server isn't giving any data in the format of a stream
You should probably use Sockets instead.
You get EOFException because nothing comes in, and the stream already finishes.
 
3:16 PM
@Unihedro actually client is a android
 
Sorry, the proper article for "Android" is "an".
 
and I am using socket in this case
socket in case of android will be running in the Androis Service
@Unihedro
ofcourse I knw this isnt the right place to ask this Q. but nobody has answer for this
Ok guyz @fge @Unihedro thanks for help... and sorry for disturbing :|
 
hello guys
 
This is awesome. xD
 
3:32 PM
lol did you make that?
 
3:53 PM
No, it was the rage on reddit
 
^^^
I've been avoiding reddit to NOT see people arguing over the colors of a dress, but I did just then, so.
 
with some comments precising that something was missing : all high rep SO users being assholes for the poor asker
(yeah, it's usually disturbing to read redditors comment about SO...)
 
"moderator nazis". xD

 In Praise of Moderators

This room has nothing whatsoever to do with criticizing modera...
in Whining Room on Meta Stack Exchange Chat, 4 hours ago, by Unihedro
"I am Hero. Rest are Zero" — ShaU March 2nd, 2015.
 
fge
@Unihedro yeah well, heroes become so when they are dead, so no worries there, right? :p
Now, back on topic...
@SecondRikudo there is another thing you should know about AutoCloseable and extending interfaces whose methods throw exceptions in general
 
Will there be a hangout? :D
 
4:07 PM
there has been one, it wasn't recorded, it was a rather short session
 
fge
Well, it's not really worth a hangout to be really honest
 
:(
 
fge
OK, let's make things quick...
AutoCloseable defines this: void close() extends Exception;
Closeable defines this: void close() extends IOException;
NOTWITHSTANDING the fact that Closeable has additional constraints to the close method, the fact is that it extends AutoCloseable
Now, why then does the close() method "refine" the contract so that what is thrown is an IOException instead of an Exception?
 
Because close isn't supposed to screw up?
 
fge
No... The answer is more simple than that
 
4:13 PM
Aha!
 
fge
This is because when you define an interface/class which extends an interface/class, you may (must in the event of a class) declare that an overriden method can either 1. throw a different exception type as long as it is a subtype of the exception thrown by the inherited interface or 2. throw no exception at all
 
Because the close method in. AutoCloseable is supposed to invoke the close method of an underlying Closeable object?
 
fge
Now, the rest depends on how you actually use your implementations
No, read above
 
... That's totally not simpler than my reasoning, albeit wrong. xD
 
fge
For instance I can define interface Foo extends AutoCloseable { @Override void close(); }
This is legal
What I @Override here is Autocloseable's close()
 
4:15 PM
Yeah
 
fge
Now, say I have an implementation of Foo
If, in a try-with-resource statement I declare a Foo foo = something, then I don't need to catch at all
BUT
If I were to use it as an AutoCloseable instead as AutoCloseable foo = something then I'd have to catch Exception
Consider this: when you use, say, an InputStream in a try-with-resource, all you have to catch is IOException, right?
(provided you don't throw it at the method level, that is)
 
Oh! I get it now!
That's awesome! It's an insightful interface design that makes it work perfectly even with custom implementations and the existing API!
 
fge
And which relies on something which has been defined by the JLS (although seldomly known) since day 1
OK, so, any questions? :p
 
Actually I do, there's something I've been wondering for months now...
Does the free candy truck actually have free candy?
 
fge
4:32 PM
...
Ohwell
sees that @Gemtastic is completely silent; maybe she has lost interest in the meantime
 
Maybe she's in danger and we should send a. search team.
 
@fge Or maybe she's so fascinated she was rendered speechless.
 
Wait, I'm actually scared now.
 
@fge Whut? no I was reading SQL stuff and getting tea
I thought the hangout was on 3NF?
 
Anyone familiar with pluralsight?
pluralsight.com
 
4:42 PM
Phew
@Gem you're alive!!!
 
Maybe I'm just a Zombie?
 
:O
NOO! It can't be! I TRUSTED YOU!
 
Are we holding this hangout?
 
fge
@Gemtastic no, this hangout, as the starred message mentions, has yet to be scheduled
What I was talking about here is AutoCloseable vs Closeable and "throwing methods" inheritance
 
@fge ah, I see
 
4:50 PM
@fge So let's schedule it :P
I think there's interest enough
 
any recommendations for advanced java tuts online?
 
Just code. Only read when you need it.
Or, read the entire Oracle JavaTM Tutorials series.
 
fge
5:05 PM
@SecondRikudo easier said than done; it was the devil's job getting all interested parties on the tdd session already
(and I still have to get that webapp version of the debugger kickstarted)
 
@fge Set an arbitrary date and record it
You can't appease everyone
@Michael can you appoint someone for RO and remove all those pins? :P
 
5:40 PM
I found a vide on SQL and the guy talking is so monotonous that it sounds like one of those "help you fall asleep" tapes :')
 
6:14 PM
@fge do you have some time?
 
6:26 PM
I'm here for you if he isn't :P
 
Wanna have a look at my draft again? To see if it follows 3NF or BCNF?
The second sheet
 
@Gemtastic aren't fuel type and year part of the brand?
 
@SecondRikudo I'm not sure
 
6:41 PM
brb, quick shower (boiler's running too much now :P)
I also want to hear what @fge has to say about it
 
Me too. He's good at pointing out the flaws in the 3NF, but I need to be better at understanding the fault :/ (sorry about that fge, I'm working on it!)
 
6:54 PM
http://www.commitstrip.com/en/2015/03/02/getting-bored-change-your-stack/
CommitStrip - Blog relating the daily life of web agencies developers
Getting bored? Change your stack
CommitStrip
1425322322
 
fge
7:06 PM
yawn
Sorry, I was away
 
It's ok
I'm the one bothering you. You can tell me to eff off if you want to :P
 
You know what would be a little ironic?
If the thing you're doing for us works and we manage to get it in an other country before we could get one here :P
 
fge
Well, two flaws already, and that is about vehicles
 
Yes! Tell me! :D
Oh no
Look at sheet 2
 
fge
7:16 PM
The model year, brand and fuel type should be in their own table (vehicle_model) and a vehicle_model_id in the vehicle table which references vehicle_model(id)
I am on sheet 2
 
Oh
To avoid confusion, can you use the names they have, however faulty they may be?
@fge I'm not sure I get what you mean :(
 
fge
OK, then drop the tables "brand" and "fueltype", create a "car_model" instead with columns brand, year and fuel_type; in the car table, add a car_model_id which references the appropriate car_model by id
Moreover I am not really sure what to do about the odometer, since it will obviously change during the car lifetime; maybe make it part of the appointment instead?
There are other things I can think of but that's the main point for me
 
Like this?
 
fge
Add an id column to car_model
 
Yeah, I noticed. I also removed the year in car
Feel free to tell me the other things you notice :3
 
fge
7:23 PM
Now, I guess you probably want something more detailed than the brand alone; the "model" as in whether it's a 330d or M5 for a BMW for instance
(two of my favorite cars, meh)
 
Oh yeah, the mdel disappeared from the new car_model table
 
fge
Depends on the requirements, of course; a mechanic will probably want to know
 
It is a requirement for the assignment; look at the grayed out tables and the one on sheet 1, it's supposed to be in there I just forgot it
Does the current car_model table follow the 3NF?
 
fge
As it stands now, yes, pretty much so
The set of all attributes other than the key fully depend on the key; if you change one attribute of one row this won't affect any other row
 
Do you think I've gone about it in a logical way?
In how I structured these tables?
I'm gonna have to star that; it's a good pointer!
 
fge
7:28 PM
One other thing is that I don't believe the payment type needs to be its own table, and it should be part of some billing table or something, not of the car owner
 
Yeah, that's true. I had my mind blown a bit yesterday, and by that new nowledge, a customer doesn't need to store the billing type or information...
More like when you make an invoice, you make the invoice know the payment type and the customer... The customer can change the billing type as it wants and technically, it could have several of them... This time I use cash, next time I want to be billed...
Am I thinking the right way?
As far as you can deduce from my rambling XD
 
@Gemtastic well, it depends
In a production app, it may be beneficial to store an encrypted credit card number for customers
 
fge
Yeah, but let's not make things more complicated than what they need to be for this assignment :p
 
@fge We really need this NF hangout :P
 
Is it still not better to store that information elsewhere and link a row with the two?
 
fge
7:42 PM
@SecondRikudo I know, I know... But this one needs time to prepare :/
 
@fge I shall await it eagerly. :3
 
@fge coworker of mine built his whole business around mongo (except for payments, which is done via REST API to an 3rd party company that deals with it)
 
fge
There is a balance to be found between formalism and practical stuff; also, it'd be nice if I had a sample database to play with and demonstrate jooq at the same time
While there is mine, it is dead simple and very easy to make it 3NF so it doesn't really count
 
@fge Well, why not model @Gemtastic's database as the model case?
 
fge
I was thinking about it, yes
 
7:45 PM
@SecondRikudo I'd be ok with that.
 
You have users, customers, vehicles, payments and the relationships between them.
 
fge
This should be a shared project
 
If you want I can think of a couple other scenarios that fit here
 
fge
That is, there is a base, there is data, and you use jooq to build your queries
Since, basically, it's SQL, meh, it will be easy to translate to pure SQL afterwards
 
@fge did you have a look at the error_message table? Do you think I managed that one well? Or should I change something?
 
fge
7:46 PM
(notwithstanding the fact that you can make pretty hairy stuff very easily)
@Gemtastic as to this one I'm still not really sure of the context; that is, what an error report should be linked to
 
@Gemtastic what database engine are you going to use? Postgres?
 
@fge I'm unsure of that, the thing is; it needs to have a relationship to an appointment so you can track the data of how long it is between the error_message and the appointment.
@SecondRikudo Undecided
But I think I'll go with Postgre
 
fge
@Gemtastic if that's only "how long", then why just not not link to anything and store the date of the error report? Since it will be tied to a particular car anyway, you can always select reports where the date is greater than the latest appointment date for this particular car
 
So I make it like this:

Error_message
########
ID
Message
Report_date
FK_CarID
FK_ReceivedBy_EmployeeID?
hm... but how do me make a good link to tween the two? A new table?
Bookings
####
ID
FK_Error_messageID
FK_AppointmentID
?
 
fge
8:11 PM
Well, first, do you need to know about the employee who received it?
Also, it is really necessary to link it to a particular appointment? The assignment was quite unclear about that
@Gemtastic @SecondRikudo what do you say this is a private bitbucket git repo?
 
@fge hmm?
 
fge
The "course support" for the hangout
 
@fge I'm not sure if the error message needs to be in there or if only needs to be who made an appointment...
 
fge
@Gemtastic we are talking about error reports here; and again, I am note sure an error report needs to be linked to this or that appointment
 
The thing is, the statistics need to be for the time in between a specific report and the appointment in which it has been fixed... Which means that a booking of an appointment should happen when you receive the error
 
fge
8:15 PM
Let's take, uh, I don't know, a faulty injector; now, the two last appointments were about replacing the turbocharger and a classical checkup. There is no telling whether the error relates to any of those two or none of them
 
How do you make that connection?
 
fge
Well, select all errors reported since the last appointment for that car, if any
(and if no appointment, make that since Jan 1st 0)
 
user3208640
hi everybody
 
Well, normally when you call to report an error and want an appointment to fix it. That's why I made the bookings table; it links a error to an appointment where it should be fixed.
 
fge
Huh, OK, that is one way to see things
 
8:18 PM
That connection makes it so that even if an appointment for something else would already be booked inbetween, it doesn't mess with the statistics
 
fge
And you probably see the difficulty in designing a model to begin with ;)
Without even getting to the *NF stuff :p
 
Well, designing a schema is difficult for me at all because this is my very first one ever :P
And I don't actually know what they're supposed to look like
 
fge
Yeah, but as you probably understand by now, there are two things: defining the business requirements and then defining the schema
 
Yep
So, yeah, it's hard :P
 
fge
If you are unsure about the former, you can be sure that the latter will be faulty to some (hopefully harmless) degree
It happens all the time
 
8:21 PM
nods that's why I've been putting so much effort into this. I could have just gone with the first draft I made and worked from there. It would work, but i would fail the assignment since it isn't 3NF or BCNF
And it would be a kinda crappy implementation
 
I'm trying to find the kth largest using this algorithm.

```
quick_select( A, k )

n = length(A)

r = round( (0+n)/2 );

pivot = A(r)

A1 = [];
A2 = [];

for i = 1:n

if ( A(i) > pivot )
A1 = [ A1 A(i) ];
elseif ( A(i) < pivot )
A2 = [ A2 A(i) ];
else
continue
end

end

if ( k <= length(A1) )
item = quick_select(A1, k);
elseif ( k > ( length(A) - length(A2) ) )
item = quick_select(A2, k);
else
item = pivot;
end

end
```

It seems to work most of the time but sometimes break due to length of A being zero at some point in recursion. what am I missing?
 
That's not java
 
@Gemtastic Not Java code. But an algorithm.
If you could help where I missed the logic.
 
user3208640
@DilipRajBaral the code you posted is unclear, don't expect us to understand it well
 
user3208640
not only the code but the title also and exactly what you want
 
fge
8:33 PM
Heh, I have an idea of a project: gtcs: @Gemtastic's Car Shop :p @SecondRikudo attacks the GUI part, I attack the server part, and @Gemtastic coordinates us both :p
 
@fge And then @Gemtastic gets all the credit on her course! Perfect!
 
fge
That's step 3 :p
 
I get to be the coordinator? Sounds like I'm on my way to be Project manager, not programmer XD
 
fge
And a good lesson in HR management as well :p
 
I kinda feel like I have to try it on my own first, otherwise I'll just feel like I'm copying your code too much
So could we have in in a week or so?
So I can try a little on my own?
 
fge
8:35 PM
As you wish, but then you can gather useful know-how from us both I believe
 
Oh, I have no doubt about that!
 
fge
In the same manner that I will certainly gain know-how from @SecondRikudo
 
I just want to avoid plagiarizing you
 
fge
It's a win-win
 
I don't wanna feel like a bystander on my own project. But this course IS about learning to work with other team members...
 
fge
8:37 PM
That's all the more reason, and you won't be a bystander by any means; you know what you want, your underlings don't :) But you can learn from your underlings as well
Again, a win-win
 
Except I don't think I'm allowed to say I collaborated with people online. "Ok, what repo did you copy paste it off of?" <-- what the teacher could say
Well, Ok then :P
 
fge
@SecondRikudo what do you say? :p
 
Well, bedtime for me now. We'll talk more tomorrow? :)
 
fge
No problem for me and have a soundless sleep night
 
@fge I have zero experience with Java GUI
If it were a webapp I'd be happy to
 
8:40 PM
I could tutor you a little?
 
fge
@SecondRikudo meh, the GUI hasn't been specified, so this can be a webapp
And in fact it most certainly will be in real life anyway, right?
 
we can make the thing we do together a webapp, and then I make mine a desktop! :D
 
fge
Who commands a desktop-only app in 2015?
 
oh well, nighty night!
 
fge
@Gemtastic we'll talk more about it tomorrow then! Go to your fluffy bed
 
fge
8:55 PM
Well, not me I'm afraid
 
9:06 PM
It's not too horrible to have the message here. It's a bit off topic, but it's not like we'd always be on topic here. As for the question, being an amateur I can't hep either.
 
Hi everyone!
 
user3208640
OK, Thank you all, no problem and as @kiheru said I'm about amateure here.
 
fge
I believe we all are
(to some degree)
 
user3208640
Hi @AlexisGamarra
 
fge
9:27 PM
stackoverflow.com/a/28819648/1093528 <-- yet another use of throwing-lambdas
 
Hi, is there a developer whom is convinced with IO streams ?
<-- doing a review on project.
1) reply as stream - OK
2) stream stored as bytes - OK
3) move byte[] into BufferedImage bufferedImage - OK
4) ImageIO.write(bufferedImage, . , .) - NOK
the bufferedImage is empty, and i don't have a clue how to figure it out why :D
 
you're sure all the previous steps worked?
 
yeah, i could get byte length. Only step 3 fails
or is the byte array corrupt itself ?
 
ok, so 3 is incorrectly marked as OK
 
cannot edit anymore ...
 
fge
9:38 PM
@KarelG which Java version is that?
 
anyway it does not seem to be a problem with IO then, but about converting byte arrays to images
 
working with JavaSE 1-7 atm
 
user3208640
if there is no problem with the byte array then this code should work (save the bytearray as image):
 
user3208640
InputStream inStrm = new ByteArrayInputStream(byteArrayOfImage);
BufferedImage bImageFromConvert = ImageIO.read(inStrm);

ImageIO.write(bImageFromConvert, "jpg", new File(
"C:/myimage.jpg"));
 
fge
Huh, I do need to provide a new version of throwing-lambdas
 
9:41 PM
according to javadoc, there is If no registered ImageReader claims to be able to read the resulting stream, null is returned.
what does that mean ? :p
 
fge
final ThrowingFunction<Path, Path> = Throwing.function(Path::toRealPath);
 
lambda's is a nice addition to Java 1.8 Finally
anonymous stuff
 
fge
@KarelG yeah, although the fact that Streams do not accept checked exception is a royal PITA (hence throwing-lambdas)
 
ah, I'll need to remember that package when I get to use 8
 
fge
@kiheru there is also a throwing-stream package; I was not confident with it so I dismissed it at first but you may want to have a look at that as well
 
9:47 PM
If i do
   System.out.println(new String(byteArrayOut.toByteArray()));
then i get (large mess)
   Y‹ÃY¢¢ÀVÖßé`I…P2í¿AsÃyk<LJ›Gæ
-ÎG®$ל¯2(_M†!Ô1o€IÆÿC­µe

But this
   BufferedImage bufferedImage = ImageIO.read(new ByteArrayInputStream(byteArrayOut.toByteArray()));
   File imageFile = new File("/image/test.png");
   System.out.println("buffered " + (bufferedImage == null));
gives null
 
fge
(to be brutally honest I haven't even tried it)
 
and i don't know why. I'm not that super good in java.
 
@KarelG Don't try to convert arbitrary byte arrays to Strings
 
fge
@KarelG why does the garbage output surprise you?
 
it doesn't surprise me, it's expected. The null surprises me
 
9:48 PM
is the data in some recognized image format?
 
@kiheru it was to test the stuff, if i'm getting replies
 
(png, jpg, ...)
 
the original file is a .png on an other server
hmmm, maybe it's because my other stream is still open ...
 
what's the type of byteArrayOut?
 
ByteArrayOutputStream byteArrayOut
 
fge
9:54 PM
@KarelG note that since you use Java 7 you can use Files.readAllBytes() to obtain the full contents of a given file into a byte[]
 
....
gotcha kill myself if that works
uhm
 
fge
Well, prepare the poison/gun, mate
Files.readAllBytes() just works
 
i need to write my bytes[] -> file
 
fge
Easy
 
not otherwise
 
fge
9:57 PM
That will write the byte array as is
Basically: if you see File, run away; think about a way to do it with java.nio.file instead, for your own sake
 

« first day (1591 days earlier)      last day (3333 days later) »