Re: problem in java highlighting

yehudivilenskes <[email protected]>
Newsgroups gmane.comp.db.oracle.toad.free
Message-ID <29292829.551571323754062453.JavaMail.SYSTEM@alvqcfw02>
 Message from: yehudivilenske

same problem me and by using the post it got solved thanks



_______________________________________

Historical Messages 


Author: yehudivilenskes
Date: Mon Dec 12 21:27:12 PST 2011
same problem me and by using the post it got solved thanks


__

Author: Michael Staszewski
Date: Mon Dec 05 08:42:09 PST 2011




 

Go to View|Options|Editor|Behavior and Edit the PL/SQL language parser. Check
out the "Sub Languages" tab and notice the "End Condition" for the Java
highlighter. Replace that text with the following.

(?-m)(\})(\s*?)((\/\s*?(\r|\n|$))|(\s*?$))

Michael


__

Author: [email protected]
Date: Fri Dec 02 08:40:36 PST 2011





Is this a bug in code, or do I need to adjust something in my highlighting
rules?
I've never configured them for java (that I recall) so this is out-of-the-box.

look at the end of the file in one of the editor windows and the end of it will
be highlighted
as if it were commented, but it isn't.

I'm using 11.0.0.116

CREATE OR REPLACE AND RESOLVE JAVA SOURCE NAMED testcomments AS
import java.sql.*;
import java.util.*;
import oracle.sql.*;
import java.lang.*;
import java.io.*;

public class testcomments {

//here's a comment, it's ok

//********* here's another one, it's ok

//and yet another good one

public static void getbanner() {
try {

//********* Use our current session, still good
Connection conn = DriverManager.getConnection("jdbc:default:connection:");

//*********** Grab the banner text, still good
Statement stmt = conn.createStatement();
ResultSet rs = stmt.executeQuery("select * from v$version");

//****** Print the results, yep, going strong
String banner;
while (rs.next()) {
banner = rs.getString("BANNER");
System.out.println(banner);
}
}catch (Exception e) {
//******** What could possibly go wrong?
String message = e.getMessage();
System.out.println(message);
}
}
//****** this comment is messed up, the /* is parsed wrong

public static void some_other_code() {
}
// the first bad comment is looking for the */ closing tag
}

 


__
_______________________________________
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.