Consider the following code:
public static void main(String[] args) { File file = new File(\"C:\\\\someFile.txt\") { public void doStuff() {
It is possible to access that method. But I don't know why you would ever want to do this.
public static void main(String[] args) { new File("C:\\someFile.txt") { public void doStuff() { // Do some stuff } }.doStuff(); }