Let's say we had such a variable:
byte[] someByteArray;
And a prototype method like this:
public void someMethodRequiringString(String someByteArray);
And then we wanted to call our method in our byte array:
someMethodRequiringString(someByteArray);
Now we understand that our method requires String instead. Let them also say that we already had a conversion function in a Util package called convertFromByteArrayToString (). What is the best way to get from
someMethodRequiringString(someByteArray);
to
someMethodRequiringString(Util.convertFromByteArrayToString(someByteArray));
My way is to place the cursor in front of someByteArray and type Util., Press CTRL + Space and Eclipse to suggest a method name for the conversion function. But, as soon as I press "Enter" to select this function, I get something like this:
someMethodRequiringString(Util.convertFromByteArrayToString(bytearray)someByteArray);
- , Util.convertFromByteArrayToString(byte [] bytearray);. , , ?