4 s!public (class db_java|[^(]* delete|[^(]* [A-Za-z_]*0\()!/* package */ $1!;
6 # Mark methods that don't throw exceptions
7 s!public [^(]*get_version_[a-z]*\([^)]*\)!$& /* no exception */!;
8 s!public [^(]*[ _]err[a-z_]*\([^)]*\)!$& /* no exception */!;
9 s!public [^(]*[ _]msg[a-z_]*\([^)]*\)!$& /* no exception */!;
10 s!public [^(]*[ _]message[a-z_]*\([^)]*\)!$& /* no exception */!;
11 s!public [^(]*[ _]strerror\([^)]*\)!$& /* no exception */!;
12 s!public [^(]*log_compare\([^)]*\)!$& /* no exception */!;
13 s!public [^(]* feedback\([^)]*\)!$& /* no exception */!;
15 # Mark methods that throw special exceptions
16 m/DbSequence/ || s!(public [^(]*(open|remove|rename)0?\([^)]*\))( {|;)!$1 throws com.sleepycat.db.DatabaseException, java.io.FileNotFoundException$3!;
18 # Everything else throws a DbException
19 s!(public [^(]*\([^)]*\))(;| {)!$1 throws com.sleepycat.db.DatabaseException$2!;
21 # Add initialize methods for Java parts of Db and DbEnv
22 s!\.new_DbEnv\(.*$!$&\n initialize();!;
23 s!\.new_Db\(.*$!$&\n initialize(dbenv);!;