|
How i can integrate my developed stemmer with Terrier Information retrieval system on window 10
|
|
|
|
|
|
Is the code from a Servlet "safe" from being viewed by an user? To make this more clear, let say that in a Servlet, you'll add a connection to a database, and because of this, from Connection object you can get the IP, port, user, password, kinda all you need to access the DB at a certain level, which is bad.
So, that being said, can a user see the code from a Servlet? Or the Servlet is just being run on the server side, and only sending out a "result" to client side, and so, the user is unable to see the actual code of a Servlet?
modified 13-Feb-19 7:48am.
|
|
|
|
|
Quote: A servlet is similar to a proprietary server extension, except that it runs inside a Java Virtual Machine (JVM) on the server . So the client user cannot access it. For full details see Java Servlet Technology[^].
|
|
|
|
|
|
Servlets run on the server. Unless there's something wrong with your server's configuration, the Java code will never leave the server.
Java Servlets - A Tutorial[^]
Also, your database server is not supposed to be accessible from the outside world. The firewall should be configured to prevent access from machines other than your server. So even if someone did manage to get the connection details, they shouldn't be able to connect to your database.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
What I said was more of an example, I haven't reached the point of using the DB yet.
Quote: Also, your database server is not supposed to be accessible from the outside world. The firewall should be configured to prevent access from machines other than your server. So even if someone did manage to get the connection details, they shouldn't be able to connect to your database.
Also this will help me when I get there. Thanks!
|
|
|
|
|
Should note however that doing that is dependent on the network setup and NOT on code.
|
|
|
|
|
Yeah, I know how to do that, it just didn't crossed my mind until now, as I said, didn't made any projects that used DB so far, but really soon I'll need it. Thanks anyway!
|
|
|
|
|
I have to make some sort of app where you need to put grades and stats for students so I have a problem here I need to have at least 5 classes and I don't know how to organize it.
Interface will be in swing and we need to use all basic OOP techniques. I need help with what classes would you make if you were to make this project. ( first time making a project..)
|
|
|
|
|
|
Member 14133670 wrote: Interface will be in swing
Presumably a class assignment.
Just noting that you probably should put more effort into the back end and spend as little time on this swing part as possible. Any use of swing is going to be very limited in the business space.
Member 14133670 wrote: I need help with what classes
I think you should do this yourself. It is like using a hammer for the first time - watching a video of someone using a hammer is not going to help you when you swing the first time. Even though you are going to hit your thumb you just need to do it.
|
|
|
|
|
Hello. Please what can I do to continue coding java ide when after running it says code too large. the codes are well above 1000 and I still need to code more.
|
|
|
|
|
Please provide some more details, your question is not clear.
|
|
|
|
|
The program is to create an excel sheet after some computations and tabulations through a designed interface.The codes is about 6000. when I continue to add more codes for further task, it displayed an error message that, code too large, after running it. Is their any way to make it run after more codes. Alternatively can you show me how to access text field from a different class to minimize the codes. thank you
|
|
|
|
|
I am sorry, but that does not make anything clearer. What do you mean by "The codes is about 6000", and where does the error message occur, and what is the exact text?
|
|
|
|
|
Ok. Can you assist me on how to access textfield from a different class in the same package (i.e to reference a JTextField from a diffrent class). Thank you.
|
|
|
|
|
From what I can understand, you have a class or method that is too long for the generated code to be able to run. You need to break it down into smaller pieces.
Referencing any item from a different class just requires a method that provides access to the item in the class.
|
|
|
|
|
Java does not allow a 'method' to be more than 64k byte codes (internal java compiled representation.)
So you have a method that is too large and you MUST break it into smaller methods. That would be the only possible solution.
In some cases if you are attempting to initialize static data, for example an array, list, etc, as a local variable you will get this error also because initialization is handled by the java compilers by creating a hidden method. Solution for that is to change how the initialization is done such as loading the data from a file.
|
|
|
|
|
Without entering in deep functionality of Servlets, what is it's use? To run some code, and at the end to redirect the user to another web page?
I'm asking because maybe there are some situations where you don't need to redirect the user to another page after the Java code from servlet is done. In this case, is there a way to stop the servlet from redirecting the user to another page? Even if you don't add a redirect or forward to the servlet, it will still redirect the user to it's map url.
|
|
|
|
|
|
Actually I've done that too, that is why I added this in my question, and why I didn't asked only it's purpose:
Quote: is there a way to stop the servlet from redirecting the user to another page? Even if you don't add a redirect or forward to the servlet, it will still redirect the user to it's map url.
|
|
|
|
|
A servlet is merely a program: it does what the code tells it to do. If you have a specific code problem then I would suggest opening a question with the details.
|
|
|
|
|
A HTTP servlet services HTTP requests, and it must finish the processing by sending a valid HTTP response to the client. The response doesn't need to be a redirect.
|
|
|
|
|
I need a human understandable definition of how java script interprets. It seems to be a dance between html pages and forms, and .js Files. I have 40 years experience in coding in 'C' and 'CPP'. The syntax of java is indeed similar. This language provides apparently no type info of any kind. params, indeed the whole of js seems to be devoid of types.
Issues are the relation between the JS Code and the pages using it That is totally unclear. Next, how do I debug Javascript. How do I set breakpoints? what software should use to code in Javascript.
Help Please!
Bram
Bram van Kampen
|
|
|
|