copy fully qualified class name

does this feature exist?

For writing emails etc. I often need to quote a specific class.
Then I always find me copying the package first, then the classname.

Is there a way to put both at once into the clipboard?


Thanks

1
Avatar
Permanently deleted user

IIRC, there is a plug-in, which does it.

0
Avatar
Permanently deleted user

CtrlAltShift+C - copy reference

9
Avatar
Permanently deleted user

Another little IDEA secret. Now I can get rid of another plugin.

"Dmitry Kashin" <no_mail@jetbrains.com> wrote in message
news:14672872.1134657404528.JavaMail.itn@is.intellij.net...

CtrlAltShift+C - copy reference



0
Avatar
Permanently deleted user

thanks!

maybe sometimes dots would be nice instead of / ;)

2
Avatar
Permanently deleted user

Depends on where you copy to :)
- Copy reference (Ctrl-Alt-Shift-C) uses dots (fully qualified name)
- Copy reference to IDEA editor magically inserts necessary imports etc.
- you can even press Ctrl-C in the popup menus (Ctrl-N etc.) and then
insert the reference. Nice if searching for symbols.
- Copy path (Ctrl-Shift-C) copies the path
... surely more

Michael Damberger schrieb:

thanks!

maybe sometimes dots would be nice instead of / ;)


1

Ctrl-Alt-Shift-C uses /  forward slash for me.  How can I get the dots instead?

4
Avatar
Permanently deleted user

Ctrl-Alt-Shift-C shows a popup with "Cannot perform refactoring", still, copy reference should be smart enough to induct that it's java class so it should be dot separated not slash.

1

Hello,

What action is mapped for "Ctrl+Alt+Shift+C" in your keymap? "Copy reference" uses dots on my machine.

0
Avatar
Permanently deleted user

I can also say that copy reference doesn't work properly even when called from `ctrl+shift+a`. It just copies the class name.

 

eg: 

```

@Component
public class PharmaPurcha[cursor is right here]seOrderLineInputValidator implements IOrderLineInputValidator
{
```

when i `ctrl+v` the only thing pasted is `PharmaPurchaseOrderLineInputValidator` and not `the.fully.qualified.package.name.of.PharmaPurchaseOrderLineInputValidator`.

If it helps i am coding in a humongous maven project with more than 50 different modules named metasfresh: https://github.com/metasfresh/metasfresh

1

@Cristian Pasat Are you pasting to an IDEA Editor or to some different location? There is a known problem: https://youtrack.jetbrains.com/issue/IDEA-137730 

1
Avatar
Permanently deleted user

@petr, it happens when i paste in idea, on windows.

0
Avatar
Permanently deleted user

I already have from the first link.

 

FYI the link you posted in both posts is half broken

wrong: `https://youtrack.jetbrains.com/issue/IDEA-137730%C2%A0`

correct: `https://youtrack.jetbrains.com/issue/IDEA-137730`

0

Its very simple and easy - which is not clearly mentioned in thread.

 

Select the class name or interface name for which you need the fully qualified path.

 

Now press CTRL + ALT + SHIFT + C to copy with dots the fully qualified name.

-2

Copy refernce will have / if your cursor is not on the class name. If your cursor is on the class name then it will have dots. It is kind of strange idea implemented this way. 

0

bharat One can use the copied string to open it in a terminal, on GitHub, or somewhere else. That is why slashes could be needed and dots are not the only option. 

0

请先登录再写评论。