RE: Reading contents of a file int a java class

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

RE: Reading contents of a file int a java class

Tashani Kathriarachchi
I tried with the following but it doesn't work for me. I got a "Failed to find entry point for component" error:


import java.io.InputStream;

import org.apache.log4j.Logger;

public class GetFileSize
{
private Logger log = Logger.getLogger(GetFileSize.class);

public static void main(String[] args) {

}

void processStream(InputStream is) throws Exception {
try {
log.info("Start of processFile");
log.info("End of processFile");
}
finally {
if (is != null) {
is.close();
}
}
}
}


What did I do wrong? --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email