Skip to content

Instantly share code, notes, and snippets.

@kevinrobayna
Last active August 29, 2015 14:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kevinrobayna/5e702ac5ada7424b3a90 to your computer and use it in GitHub Desktop.
Save kevinrobayna/5e702ac5ada7424b3a90 to your computer and use it in GitHub Desktop.
package test;
import java.util.Locale;
import com.github.rodionmoiseev.c10n.annotations.Es;
import com.github.rodionmoiseev.c10n.C10N;
import com.github.rodionmoiseev.c10n.annotations.DefaultC10NAnnotations;
import com.github.rodionmoiseev.c10n.annotations.En;
import com.github.rodionmoiseev.c10n.annotations.Ru;
interface Message {
@En ("Hi")
@Es ("Hola")
@Ru ("Привет")
String grettins ();
}
public class TestMain {
private static Message msg;
public static void main (String [] args) {
C10N.configure(new DefaultC10NAnnotations());
msg = C10N.get(Message.class);
System.out.println(msg.grettins());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment