How would you test google maps? - java

I came across this in an java interview earlier. It was one of the only question I wasn't able to answer merely through lack of familiarity with google maps integration.
Can anybody let me know what would have been a model answer? Research from google searches point me to Selenium but I'm not sure if I'm even on the right track?
p.s I'm not sure whether I posted this question in the correct manner but apologies in advance.

Selenium is a fine example. Check out some of their example videos. Selenium is basically a way to test an application without having any access to its innards.
Either way, I'm sure there would be a follow up question with more specifics, so play around with it to get a feel for what it does.

Related

How can I retrieve database data and present it in an application

I am currently working on an application in android studio as I am trying to learn how to use it in my spare time, my knowledge is very low so I was hoping I can explain the concept of my app and ask people for some pointers in different techniques I could use. The basic idea of my app is that it works by allowing people to search for a celebrity and it shows a few facts about them, their date of birth etc. I know its nothing special but it is literally a concept to help me improve my android studio knowledge.
My main issue with this is getting the information from the database into the application in an easy to read and presentable way, what sort of things should I be researching to help me achieve this, from my knowledge I believe I would need to set up a scanner to take the users input, then search the database to find the information and then I need to find a way to return the results in a presentable manner.
Apologies if this is too long winded a question, and thank you to everybody who takes the time to read and respond to me.
If you are looking for some API then check this out this can be help full.
https://api-ninjas.com/api/celebrity
You can even check if Wikipedia have any API for providing info.
I found this also
http://en.wikipedia.org/wiki/Wikipedia:Creating_a_bot#APIs%5Ffor%5Fbots
It appears there's also an API for IMDB: http://www.deanclatworthy.com/imdb/

Wanting to write web applications in Java, I'm in total bewilderment concerning which platform/framework/language to use? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 12 years ago.
I'm currently confused about the many options concerning developing Web Applications with Java. I've worked on some Java programming using Servlet/JSPs only, in the past most of my work was on PHP.
I'm trying to select a good base for me to start. The options I've considered are the following:
Option 1. Pure JSP/Servlet programming with Hibernate for the Back-end.
Problems: Maintaing a web.xml for every servlet, strict types, needing to recompile and restart tomcat everytime a change is made, lots of code.
Option 2. Groovy on Grails
Problems: Still not a mature technology, might be difficult to debug, might turn out to be slow.
Option 3. Web Application development using the Spring Framework
Problems: Seems like a chubby framework. Skeptic about it, I dont want to be limited by a framework that covers everything, I prefer using small vertical libraries like Guice, Hibernate, JSP/Servlet.
Out of my scope: JSF, Struts, Tapestry. Those three I didn't feel comfortable reading about or using.
I need help, can anyone please provide me a relieving answer to the above? Thanks.
If you can not decide on what to use, there are only 3 ways to do it, and the choice is yours:
Open your local job-search web page and find which technologies are currently popular in your region. If you choose it this way - you will have most money (statistically you should).
Input various technologies in the search box on stackoverflow and see the amount of results. Pick up the one with most results. This will mean the biggest community resulting in getting the help easier if something goes wrong.
Trying them all out yourself. Every human is different, there are ones prefering assembler, and other trying to code everything in Javascript. You can't just ask which of the platforms is generally better - you have to try them out yourself.
I suggest to add the play framework to your list.
Just another links for my commentators ;) : How to demo the play framework
BTW - my recommendation is mainly based on their tutorial. After studying these pages, I thought for the first time, next time I do a web application. Those guys seem to know what web developers really need. (again - my personal impression)
I recomend to use GWT, you can keep programming in pure java
http://code.google.com/intl/es-ES/webtoolkit/
Then all pure java experience, books, libraries and hours of work will be useful without needing another language, that was the google idea behind that.
There is also a Java Web Toolkit (and one for C++), but I haven't tried them yet
http://www.webtoolkit.eu/jwt
Option 1: It's a good option if you add some libraries to it to avoid re-programming what it has been programmed already (see out of scope paragraph)
You don't need to maintain a web.xml for every Servlet. You must maintain one web.xml per application running in Tomcat. Strict types = less bugs. What's the problem with restarting tomcat? You develop with Eclipse for example, who has a server integrated so you don't need to deploy to see your changes and when you reach certain milestone or release, you deploy to production server.
Option 2: I have no experience whatsoever with it. But slow? Don't think so. Difficult to debug? You come from PHP...I'm sure you find it easier :).
Option 3: Spring is a huge factory with tons of various tools and items. Then you take that items and construct a bike or a tank out of them. (Thanks to Max comments)
Out of your scope: JSF is on top of JSP so does a lot of stuff for you, and helps you develop a MVC pattern. It provides you with a nice framework, which is easy to understand if you already know JSP. I'd give it a second try. Also consider using GWT, maybe is what you are looking for.
My two cents: I'd go with Hibernate and JSF (and Richfaces) or GWT. You'll learn, you'll have fun, you'll get what you want. Grails and Groovy has become really popular lately. I'm sure if you choose them you'll learn and have fun too.

Java - How to refresh knowledge? (2 years ago)

I have my first ever interview for a Java developer role, specifically RMI, Serverlets and JDBC.
However, it has been a while (2 years) since I have done any Java coding. I am sure I still have it up there somewhere and I do remember the Java syntax
I wanted to ask how can I re-fresh everything in 2-3 days specially the OOP concepts (polymorphism, inheritance) specifically to Java?
Any links, references and tutorials appreciated.
I am new to this site and I see there is a preference for programming related questions, hope I can get away with this!
Would also appreciate those that know any Java interview questions so I can go through them and test myself.
Thanks all
I'd suggest you you test yourself, e.g. on Java Black Belt, which has a good question base grouped by categories and detailled explanations for your mistakes.
I'd also recommend (re-)reading Sun's Java Tutorial and (longer) Thinking in Java by Bruce Eckel (3rd edition is free to download).
Tutorials on RMI
Java Servlet Technology
JDBC Tutorials
OOP concepts (polymorphism, inheritance): Head First Design Patterns
Java Interview Questions
How about this. Take a certification guide. It will save you a lot of time, and give you an exercise after every chapter (might give you some interview questions). You don't need to bore you down to death by teaching yourself in a wordy way, what you might already know. The best would he Khalid's Java Certification Guide. Believe me it would be faster and more effective. Plus give you the skills for appearing in the test for real, if you like to. :)

java classifieds application

Does anybody know of a good classifieds application written in Java?
Update
... by "classifieds application", I mean an application which handles buying and selling, advertisements etc., something like "http://www.ikiclassifieds.com/" but only written in Java.
Google, as always, would appear to be your friend in this case; "classified ads java" yields various directories which would appear to link to such products, although I can't say I've inspected the results in any great detail.
This is a pretty broad question, soliciting general opinions without providing any kind of real detail relating to what it is you're looking for. You might as well have said, "recommend a blog engine written in Java", for which you could easily have done your own research and found solutions to meet your needs.
More interesting questions might include, "I'm developing a classified ads solution in Java and I'm stuck with this particular aspect", or even, "does anyone have any specific experience with XYZ, the Java-based classified ads system; I'm trying to evaluate it".

Programming with Java for beginners [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I am a registered Student at a university in Switzerland, thus I know that programming is part of Electrotechnik (electrical engineering), the field I am going to take.
How can I learn programming with Java with easiest way, and without help by others?
I tried it through learning books, but I found it not easy, especially to do it alone.
For someone that knows nothing about programming, just reading tutorials will not do it for you. It would be good to download an editor and actually write the programs with any tutorial you use.
The thing about programming, the more you actually write the better you get at it.
Grüß, Thomas, if you haven't learned any programming it may be a little hard to start, but the Sun Java Tutorials are a good place to start.
Try the Java Tutorial. It will walk you through actual examples, with code that you can try out in various IDEs. I usually find that easier than reading a book.
Head First Java is good, if you can get past the style. Some people like it, others hate it (I haven't found anywhere in between). The funny part is the ones that like the style are the people who have more experience I find (not 100% true) but the book is aimed at those with little experience.
If you like the style it is a good book, if you hate the style, there are others, just let use know (as others have asked), are you 100% new to programming and if not what other languages do you know. Also what part(s) of the langauge are you having trouble with in particular?
In fact you have to learn two things, programming and Java.
I would recommend the book thinking in Java (Bruce Eckel), the current version is the 4th edition but you can download the 3th revision for free...
What books have you tried so far? When I started someone recommended to me "Sprechen Sie Java?" my Hanspeter Mössenböck which actually worked pretty well for me back then (having written not a single line of code before starting with Computer Science).
You could try a free course at Javapassion.
Another option for you if want to get a jump on your studies, you could go through the open courseware from M.I.T. For example, the Intro to Java Course.
Try the FREE book Java Programming for Kids, Parents and Grandparents by Yakov Fain
Get yourself set up and complete a "Hello World" tutorial, there are so many all over the next.
Once you know you can compile a Java program and view the output. Think of a small program. It might something as simple as converting Celcius to Fahrenheit and vice versa. Build that, using Google and whatever other resources you need to to find what you need to do. Once you get that running, think of something more complicated. Build that, keep doing this for a little while.
By building real apps, that give you something you want you will be much more motivated and you will understand what you are doing better because all the curly details haven't been solved for you the way they are in online or book tutorials. You may not use the most elegant design but you will learn more.
However at some point you will need to start to delve into books about Object Oriented architecture etc. but for now just jump in and force your brain to learn.
Another vote for actually doing some coding here. If you don't like the exercises in books then try programming something you're interested in personally. In my quest to learn C# I'm writing a program to correlate and display photos and GPS tracks and as a spin-off I'm trying to write a 3D graph component in WPF. Having a real problem I'm actually interested in makes a big difference to me, you can get a bit tired of implementations of bank account classes and vehicles.
Take a look at BlueJ. It was designed to teach Java
I recommend the Stanford course CS106A, which is available for free to download, and can also be found on iTunes. It's a great course, and the teacher is very enthusiastic:
http://www.stanford.edu/class/cs106a/
I agree with others that the Sun tutorials and the Thinking in Java free book are excellent, however, I don't think they can replace a video for someone completely new to the field.

Categories

Resources