java get Chars

getChars() StringBuffer Example

To convert StringBuffer contents to an array of characters with getChars() StringBuffer. Sometimes, it may be needed to copy a few characters of string content of StringBuffer to an array or to copy the complete StringBuffer into an array. Here, getChars() method comes into usage. What Java API says about…

getChars() String Example

java.lang.String class comes with many methods to manipulate string. The methods are a boon to Programmers without which would have been a laborious code like C/C++. Present method is getChars() String. getChars() copies the characters of a sting to a character array. Or, a string can be converted into a…