If you don't want to add the ports sources to your system, you can install from binary packages.
Java on FreeBSD is the OpenJDK implementation, for Java7, the command should be
pkg_add -r openjdk
While for Java6, it is:
pkg_add -r openjdk6
Due to redistribution restrictions, it isn't possible to use 'pkg_add -r' to install the linux distribution of Oracle JDK. Also, the linux emulation is only 32-bit. So, the java/linux-sun-jdk17 port would use "jdk-7u25-linux-i586.tar.gz".