Is there a fast way to click on a Java class in Eclipse and obtain its fully qualified name, or copy it to the clipboard?
The fully qualified name of a class is the name of the class prefixed with the package name. For example if class Address is in a package com. mycompany. myproject , then the fully qualified name of class Address is com.
In When, select 'Editing Text'. Click Apply and OK. Now, in your java editor, keep the cursor on any element and press Ctrl+Q. That copies the qualified name of the element.
3) Using fully qualified name Now there is no need to import. But you need to use fully qualified name every time when you are accessing the class or interface. It is generally used when two packages have same class name e.g. java.util and java.sql packages contain Date class.
The term fully qualified file name (or FQFN) means a file on a computer whose exact name is completely specified such that it is unambiguous and cannot be mistaken for any other file on that computer system.
Edit on 2016-06-29:
As pointed by Jeff, you only need the 2nd step in the following:
1. Double-click on the class name in the source code.
2. Right-click and select "Copy Qualified Name"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With