Bruno Sofiato

  • Content count

  • Joined

  • Last visited

Community Reputation

407 Neutral

About Bruno Sofiato

  • Rank
  1. Profile and play with garbage collector settings and VM's optimization options.   The newer GC's algorithms are optimized to deal with short lived object. There is also the escape analysis optimization, which was incorporated to the newer Java versions. The escape analysis can, by analysing the code in runtime, determine if the created object will be allocated on the heap or could be allocated on the "stack".   More info at
  2. So I'm preparing to ask my girlfriend to marry me

    It really depends, if you're willing to marry her, you must know (I really hope so) a lot her, about how she fells and what she finds funny or of a bad taste. What are your feelings telling you ? 
  3. Violent vs Non Violent Protests

    So the ends justifies the means ? Sorry but I can condone that, if there's another, less extreme way, it should been tried. Sure, sometimes it will eventually lead to more extreme form of conflict, but it shouldn't be the first option, it shouldn't be desired by any of the involved parties.   And in war, the people doesn't get what they want. The people in charge of the winning side get what they want.
  4. Moving to Canada

    Where do you live in Brazil ? at 20 celsius I'm sweating 
  5. Violent vs Non Violent Protests

    I live in Brazil, and I can that brazilians always thinks that in Europe or in the US everything is perfect. But in reality many doesn't know how other countries really work. As it was already been said by samoth, the german education system by far more excludent than ours (AFAIK if you don't have good grades in the first 4 years of school, you're bound to go to a kind of school where you can't go to the university). I've been told (by foreigners) that São Paulo's subway system is quite good, but if you ask a brazillian, he/she'll always tell you that the system is a big piece of crap. The last time I was in Berlin, I paid 2,4 Euro a subway ticket, way more expensive than the fare down here (even with the price raise).    Those protest are by no means unjustified. There're serious problems down here like the income disparity, corruption, administrative problems. The government always focusing on tourism and commodities instead of building a competitive industry. Even so, I just can't condone violence as non-violent protest can be very effective when it affects one money making ability.   What is really troubling is the World Cup and the Olympics. The government is expending like hell on things that are not a priority. More so, FIFA is pushing some demands that go against brazillian citizens rights and our government are complying with.   E.g : There's a law that ensures that the elderly and students should paid half price when attending cultural and sport events, FIFA has been pushing to revoke this law.  It's also against the law to sell alcohol in stadiums (ok, it's not a citizen's right per see, but a question of state sovereignty, which is also troubling), but FIFA made lobby to revoke this law also.
  6. Version control don't lead to better code per se, it leads to a better software configuration management. When you say improve code, are you referring to the code by itself or the quality of this code to realize a requirements' set ?
  7. If it's white box testing that you're looking for, you could use a mocking framework (like Easymock or Mockito) and test only the EventManager's dispaching logic. It's relatively simple to ensure that the registered callbacks are indeed being called.   P.S. I'm assuming this is in Java .
  8.   This, I tend to frown up those so called architects who doesn't have a clue on how to materialize the envisioned into a real, usable system. A system architect should not (IMO) be a job title, but a role that a software engineer (usually the most senior) embraces.
  9. Keyboard rage

    It's an USB keyboard ? If so, have you attached a new peripheral lately ? AFAIK the usb bus is shared between all attached peripherals so it could be a timing issue between them (just a guess).
  10. Convert std::string to WCHAR ?

    My C++ is a bit rusty ... but perhaps  std::wstring toWideString(std::string & str) {   std::wstringstream ws;   ws << str.c_str();   return ws.str(); } 
  11. Laptop or PC for development?

    I always use desktops when I have the choice. But I'll eventually buy a notebook for light work.
  12. Up casting and ClassCastException

    Try this :   public class GameObject implements Cloneable {   public GameObject getClone(float x, float y) { try {     GameObject go = (GameObject)(super.clone());       //Clone the data here       return go; } catch (CloneNotSupportedException ex) { throw new RuntimeException(ex); }   } }    P.S. I don't think that your clone method should receive any parameter. Try to keep the cohesion of the methods.
  13. java swing link to new window here some info on creating links on swing.     P.S. I've not tested this code, so I don't know if it has errors or such
  14. War with North Korea

    I was just supplying info, As I read the article I was suprised that the situation was that bad, so I decided to share.