come with me, on the way I'll explain.
CEJUG Podcast #2
O Igo Coelho recebe neste episódio eu e o Amaury Brasil, falamos sobre o que é o CCT, PUJ e os temas do próximo encontro dia 23 de março de 2009 na UNIFOR. Apresentando o LWUIT com Daniel Valente e Introdução a programação em Java para a TV Digital com Amaury Brasil.
Fotos da gravação lá na Fortes.
Parabéns ao Igo Coelho mais uma vez pela iniciativa e a todos que contribuíram para fazer mais esse episódio do CEJUG Podcast acontecer. ;D
No comments yet.
The Caps Lock Java Socket Server
27 February, 2010 - 9:39 pm
Tags: caps lock, Java, programming, socket, upcase
Posted in english | No comments
Here is a simple server for those who are starting studying sockets or just needs a simple socket server example for reuse while writing your own behavior.
Features:
A client should enter a string and the server would answer the same string, with each symbol in up case, when possible.
Default port at 8080.
One client at time.
No multi [...]
Beware the locale
22 February, 2010 - 5:16 pm
Tags: development, i18n, Java, JUnit, locale, programming, String, teste unitário, toString, unit testing
Posted in english | No comments
Today I was programming a toString method for a class widely used in a application, using the very useful String.format that provides a C’s like printf formatter.
@Override
public String toString() {
return String.format("VO[a: %.1f, b: %.1f, c: %.1f]", a, b, a+b);
}
%.1f means a float with one digit precision after the dot separator. The code [...]
1º Café com Tapioca de 2010
9 February, 2010 - 3:49 am
Tags: Atlântico, Caelum, café com tapioca, CCT, CEJUG, José Donizetti
Posted in english | No comments
Essa quarta-feira acontece o primeiro CEJUG Café com Tapioca de 2010.
O foco serão duas palestras ministradas pelo José Donizetti da Caelum, sendo a primeira sobre VRaptor 3 e a segunda sobre Test Driven Development.
O evento será realizado no auditório do Atlântico.
Maiores informações no site do evento.
Java Font List
5 January, 2010 - 6:10 pm
Tags: AWT, fonts, Java, JVM, Larabie, Larabie Fonts, programming
Posted in english | Comments Off
Here’s a program that lists fonts available in your JVM. You can also set the environment variable JAVA_FONTS to specify the font directory.
import java.awt.GraphicsEnvironment;
public class ListFonts {
public static void main(String args[]){
GraphicsEnvironment e = GraphicsEnvironment.getLocalGraphicsEnvironment();
for(String font:e.getAvailableFontFamilyNames()){
System.out.println(font);
}
}
}
By using pipes you can count how many fonts you have:
java ListFonts|wc -l
On my Ubuntu machine here I got 556 because [...]
Tiled TMX Map Loader for Pygame
I’m using the Tiled Map Editor for a while, I even wrote that tutorial about it. It’s a general purpose tile map editor, written in Java but now migrating to C++ with Qt, that can be easily used with my set of free pixelart tiles.
A map done with Tiled is stored in a file with [...]
CEJUG Tech Day 2009
2 December, 2009 - 12:05 am
Tags: Caelum, cartaz, CEJUG, evento, Fanor, Fortes, poster, Sun, Sun Microsystems, Usix, Usix Technology
Posted in português | No comments
O Grupo de Usuários Java do Ceará estará realizando no próximo dia 04 de dezembro o CEJUG Tech Day na Fanor.
Este ano, precisamente nos dias 8 e 9 de dezembro, a Sun Microsystems estará realizando a edição 2009-2010 do Sun Tech Days, em São Paulo. Provavelmente será o último STD realizado. Felizmente, teremos mais uma [...]
Java: Accessing Private Members
14 November, 2009 - 4:27 am
Tags: Class, Douglas Adams, Field, getclass, getDeclaredField, Hack, Hacking, Java, Life, Object, Object-Oriented Programming, OOP, Reflection
Posted in english | 3 comments
Using reflection to change the accessibility of a private object field and access it at runtime.
import java.lang.reflect.Field;
class Life {
private int meaning = 42;
}
class Hack {
public static void main(String args[]){
Life life = new Life();
[...]
Jedi Name
8 November, 2009 - 5:47 pm
Tags: Java, Jedi, joke, programming, star wars
Posted in english | No comments
A simple Java class that calculates your Jedi name based on your first, last name, mother’s maiden name and the city you grew up.
/*
Jedi first name: 1st 3 letters of last name + 1st 2 letters of first name
Jedi last name: 1st 2 letters of mother’s maiden name + 1st 3 letters of [...]
Duke Arrow Signs
18 September, 2009 - 2:48 pm
Tags: arrows, CEJUG, duke, Inkscape, Signs, SVG
Posted in english | No comments
For arrow signs on events.
Source: duke_arrow.svg
Cameraman Duke
One more Duke.
Source: cameraman_duke.svg













