As for how Japanese feel about foreigners... mindsets have changed throughout the years, and now, different groups of people think differently about foreigners. So it's hard to come up with a specific answer.
In general, the Japanese are uncomfortable with anyone who does not behave like a typical Japanese (being loud, saying what's on their minds, no Japanese manners etc).
Looks matter too: On the train, Japanese people tend not to sit or be near people who don't look Japanese - whites, blacks, etc. Because they look different, and can seem intimidating. For me, coz I look like a Japanese, I don't have encounter such a problem.
Such cases are less common in big cities, where the Japanese are used to seeing foreign-looking people around them.
And then, there is another group: In the big cities, some Japanese take the initiative to go up and talk to foreign-looking people, and get friendly with them. These are the people who like the non-Japanese traits of speaking your mind, being "rude" in the Japanese sense, etc.
So, bottomline: How each Japanese views foreigners really depends on the individual.