"deprecated API" error

hi, this is my first post!

i get this error when i try to compile my program:

Note: C:\project\LightGame.java uses or overrides a deprecated API.

Note: Recompile with -Xlint:deprecation for details.

i think the function with the problem is the following one:

publicboolean mouseUp(Event event,int x,int y){

if (end == 1){

init();

update(getGraphics());

}else{

if (x > 210 && x < 270 && y > 165 && y < 185){

init();

update(getGraphics());

}

int column = (int)(x / (WIDTH / 5));

int row= (int)(y / (WIDTH / 5));

board[column][row] = -board[column][row];

try{

board[column+1][row] = -board[column+1][row];

}catch(Exception e){

}

try{

board[column-1][row] = -board[column-1][row];

}catch(Exception e){

}

try{

board[column][row+1] = -board[column][row+1];

}catch(Exception e){

}

try{

board[column][row-1] = -board[column][row-1];

}catch(Exception e){

}

countLight();

if (end == 0){

update(getGraphics());

}

}

returntrue;

}

i think this is the function with the problem because when i deactivate

it (make it //comment) compiler does show up the error.

I can't understand what is that error and how to fix it...i am new in Java

programming...

If it's nessasary i can post the whole program but i didn't want to flood

my post. If anyone wants the whole program just tell me and i will post

it!

thanks alot!

[3054 byte] By [StorM_GmAa] at [2007-11-27 3:26:29]
# 1

What you should do is what it says: recompile putting -Xlint:deprecationafter javac. If you use an IDE you will have to figure out how it allows you to add switches like this.

When compiled this way the compiler will give you more information about where the offending code is. "Deprecated" refers to code that will work (hence it's a warning not an error), but which is outdated.

I can't see what might be the problem with this method - maybe it's within init() that the problem lies; in any case the compler will tell you.

pbrockway2a at 2007-7-12 8:29:12 > top of Java-index,Java Essentials,Java Programming...
# 2
By the way: do you mean update(getGraphics()) or repaint()?
pbrockway2a at 2007-7-12 8:29:13 > top of Java-index,Java Essentials,Java Programming...
# 3
thanks for your answer pbrockway2!but i don't understand where should I put the -Xlint:deprecationi am using JCreator to compile my program...sorry for bothering you...
StorM_GmAa at 2007-7-12 8:29:13 > top of Java-index,Java Essentials,Java Programming...
# 4
no update(getGraphics()); is what should be there mate...
StorM_GmAa at 2007-7-12 8:29:13 > top of Java-index,Java Essentials,Java Programming...
# 5

I've never used JCreator, but the following instructions may help. They're copied from here: http://www.jcreator.com/forums/index.php?showtopic=1699&hl=deprecated

1 Go to Configure>Options>JDK Tools

2 Select the Compiler from the drop-down menu

3 Click New...

4 Go to the parameters tab and add the parameter "-Xlint" to the beginning in the text field.

5 Name the tool configuration "Xlint" or something similar

6 Press OK and OK again

7 Go to Project>Project Settings>JDK Tools

8 Under the Compiler menu, check the "Xlint" box

9 Press OK and compile your project

pbrockway2a at 2007-7-12 8:29:13 > top of Java-index,Java Essentials,Java Programming...