Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

import java.io.IOException;
import java.nio.file.LinkOption;
import java.nio.file.Path;
import java.nio.file.Paths;

public class Main {

    public static void main(String[] args) {

        Path path = Paths.get("/tutorial/Java/JavaFX", "Topic.txt");

        // convert path to "real" path
        try {
            Path real_path = path.toRealPath(LinkOption.NOFOLLOW_LINKS);
            System.out.println("Path to real path: " + real_path);
        } catch (IOException e) {
            System.err.println(e);
        }

    }
}