public class AwfulRegExpMatcher {
/** Create a matcher with the given regular expression and which will
operate on the given input string */
public AwfulRegExpMatcher(String regExp, String inputText);
/** Retrieve the next match of the pattern against the input text,
returning the matched text if possible or null if not */
public String getNextMatch();
}
public class BadRegExpMatcher {
public BadRegExpMatcher(String regExp);
/** Attempts to match the specified regular expression against the input
text, returning the matched text if possible or null if not */
public String match(String inputText);
/** Get the next match against the input text, or return null if no match */
public String getNextMatch();
}
class BetterRegExpMatcher {
public BetterRegExpMatcher(...);
/** Provide matchers for multiple formats of input -- String,
character array, and subset of character array. Return -1 if no
match was made; return offset of match start if a match was
made. */
public int match(String inputText);
public int match(char[] inputText);
public int match(char[] inputText, int offset, int length);
/** Get the next match against the input text, if any */
public int getNextMatch();
/** If a match was made, returns the length of the match; between
the offset and the length, the caller should be able to
reconstruct the match text from the offset and length */
public int getMatchLength();
/** Convenience routine to get the match string, in the event the
caller happens to wants a String */
public String getMatchText();
}
About the author
Brian Goetz is a professional software developer with over 15 years of experience.
He is a principal consultant at Quiotix, a software development and consulting
firm located in Los Altos, Calif.
In Part 3, I'll look at some of the performance issues specific to distributed
applications and show how to spot and eliminate them at design time.
在第三部分中, 我将看看分布式的应用程序中特有的性能问题, 怎样在设计时候找出和消
除它们
About the author
Brian Goetz is a professional software developer with over 15 years of
experience. He is a principal consultant at Quiotix, a software development
and consulting firm located in Los Altos, Calif.
About the author
Brian Goetz is a professional software developer with more than 15 years of
experience. He is a principal consultant at Quiotix, a software development
and consulting firm located in Los Altos, Calif.
作者: cinc 时间: 2002-11-26 09:24 标题: 为JAVA性能而设计(1(转贴) 呵呵,讲的真是细,居然忘了精华