Lesson: Regular Expressions (The Java™ Tutorials > Essential Classes) This lesson explains how to use the java.util.regex API for pattern matching with regular expressions.
Although the syntax accepted by this package is similar to the Perl programming language, knowledge of Perl is not a prerequisite. This lesson starts with the basics, and gradually builds to cover more advanced techniques. Introduction Provides a general overview of regular expressions. It also introduces the core classes that comprise this API. Test Harness Defines a simple application for testing pattern matching with regular expressions. String Literals Introduces basic pattern matching, metacharacters, and quoting. Character Classes Describes simple character classes, negation, ranges, unions, intersections, and subtraction. Predefined Character Classes Describes the basic predefined character classes for whitespace, word, and digit characters.
Quantifiers Explains greedy, reluctant, and possessive quantifiers for matching a specified expression x number of times. Capturing Groups. Features new in Java 7 Forum at JavaRanch. Java SE Technical Documentation. Java Applets,Free Java Applet,Java Applets Tutorial,Download Java Applets,Java Applet Tutorials. Learn how to download applets and decompile Java class files - Part 2. By Alvin Alexander.
Last updated: Sep 16, 2013 Update This article is a little old now, so I've started a new series (as of April, 2010) on Java decompilers and obfuscators. Please follow that link for much more recent information. The content below is kept here only for legacy reasons. Introduction In our previous article, we demonstrated a simple method that can be used to easily download the class files of Java applets. Why do this? If you're just joining us in Part 2 of our series, I feel the need to explain why we're doing this series in the first place: First, we're a Java educational center.
Obtaining software to decompile Java class files To decompile a Java class file, you're going to need some software specially made for decompiling Java class files (also called reverse-engineering). Mocha is probably not the best decompiling software available today, but it is one of the first packages available - if not the first - and it's also free. Step 1: Download Mocha Step 2: Install Mocha. Java, ProGuard, and Ant - How to obfuscate Java class files with ProGuard. By Alvin Alexander.
Last updated: Sep 16, 2013 Java obfuscator/obfuscation FAQ: How can I obfuscate my Java class files so they can't easily be decompiled? (Or, how do I use ProGuard to obfuscate my Java class files?) As I've written before in Java decompilers and obfuscators, if you're sharing a Java application with other people, and you don't want them to be able to easily decompile your Java class files, you're going to want to obfuscate your Java class files.
One way to obfuscate your class files is with a tool named ProGuard. Using ProGuard with Ant to obfuscate Java class files As I mentioned in an earlier article, you can easily decompile Java class files with a tool given the name "Java Decompiler Project". If you're selling a Java application, or trying to protect trade secrets while distributing Java class files, the counter measure to this is to obfuscate your Java class files. As you can see from the code, my Ant obfuscate task use the proguard Ant task to do its work. ProGuard. yGuard - Java Bytecode Obfuscator and Shrinker. yGuard is a free Java bytecode obfuscator and shrinker that improves your software deployment by prohibiting unwanted access to your source code and drastically shrinking the processed Jar files at the same time.
The current yGuard version is 2.5. Please refer to the requirements and changelog for details about the latest version. Features yGuard is absolutely free! Contrary to expensive commercial products of our competitors providing the same amount of features as yGuard or less, yGuard is free. Why Use yGuard? Name Obfuscation: protects your .class files from reverse engineering by replacing package, class, method, and field names with inexpressive characters. Documentation The yGuard Manual is a detailed user guide which will enable you to use yGuard as an ordinary Ant task. Requirements To run the yGuard software, you need JDK 1.4.x or greater and Ant 1.5.x or greater (it might be compatible with earlier versions of either software, this has not been tested, however).