viernes, 6 de diciembre de 2013

Metodos de la clase String en java – Curso – Texas

Mencionemos algunos métodos de la clase String y su funcionamiento.

El siguiente cuadro fue extraído de la documentación de java en el sitio web oracle.com.

Versión Ingles:

Method Summary
charcharAt(intindex)
Returns the character at the specified index.
intcompareTo(Objecto)
Compares this String to another Object.
intcompareTo(StringanotherString)
Compares two strings lexicographically.
intcompareToIgnoreCase(Stringstr)
Compares two strings lexicographically, ignoring case differences.
Stringconcat(Stringstr)
Concatenates the specified string to the end of this string.
booleancontentEquals(StringBuffersb)
Returnstrueif and only if thisStringrepresents the same sequence of characters as the specifiedStringBuffer.
staticStringcopyValueOf(char[]data)
Returns a String that represents the character sequence in the array specified.
staticStringcopyValueOf(char[]data, intoffset, intcount)
Returns a String that represents the character sequence in the array specified.
booleanendsWith(Stringsuffix)
Tests if this string ends with the specified suffix.
booleanequals(ObjectanObject)
Compares this string to the specified object.
booleanequalsIgnoreCase(StringanotherString)
Compares thisStringto anotherString, ignoring case considerations.
byte[]getBytes()
Encodes thisStringinto a sequence of bytes using the platform's default charset, storing the result into a new byte array.
byte[]getBytes(StringcharsetName)
Encodes thisStringinto a sequence of bytes using the named charset, storing the result into a new byte array.
voidgetChars(intsrcBegin, intsrcEnd, char[]dst, intdstBegin)
Copies characters from this string into the destination character array.
inthashCode()
Returns a hash code for this string.
intindexOf(intch)
Returns the index within this string of the first occurrence of the specified character.
intindexOf(intch, intfromIndex)
Returns the index within this string of the first occurrence of the specified character, starting the search at the specified index.
intindexOf(Stringstr)
Returns the index within this string of the first occurrence of the specified substring.
intindexOf(Stringstr, intfromIndex)
Returns the index within this string of the first occurrence of the specified substring, starting at the specified index.
Stringintern()
Returns a canonical representation for the string object.
intlastIndexOf(intch)
Returns the index within this string of the last occurrence of the specified character.
intlastIndexOf(intch, intfromIndex)
Returns the index within this string of the last occurrence of the specified character, searching backward starting at the specified index.
intlastIndexOf(Stringstr)
Returns the index within this string of the rightmost occurrence of the specified substring.
intlastIndexOf(Stringstr, intfromIndex)
Returns the index within this string of the last occurrence of the specified substring, searching backward starting at the specified index.
intlength()
Returns the length of this string.
booleanregionMatches(booleanignoreCase, inttoffset,Stringother, intooffset, intlen)
Tests if two string regions are equal.
booleanregionMatches(inttoffset,Stringother, intooffset, intlen)
Tests if two string regions are equal.
Stringreplace(charoldChar, charnewChar)
Returns a new string resulting from replacing all occurrences ofoldCharin this string withnewChar.
booleanstartsWith(Stringprefix)
Tests if this string starts with the specified prefix.
booleanstartsWith(Stringprefix, inttoffset)
Tests if this string starts with the specified prefix beginning a specified index.
CharSequencesubSequence(intbeginIndex, intendIndex)
Returns a new character sequence that is a subsequence of this sequence.
Stringsubstring(intbeginIndex)
Returns a new string that is a substring of this string.
Stringsubstring(intbeginIndex, intendIndex)
Returns a new string that is a substring of this string.
char[]toCharArray()
Converts this string to a new character array.
StringtoLowerCase()
Converts all of the characters in thisStringto lower case using the rules of the default locale.
StringtoLowerCase(Localelocale)
Converts all of the characters in thisStringto lower case using the rules of the givenLocale.
StringtoString()
This object (which is already a string!) is itself returned.
StringtoUpperCase()
Converts all of the characters in thisStringto upper case using the rules of the default locale.
StringtoUpperCase(Localelocale)
Converts all of the characters in thisStringto upper case using the rules of the givenLocale.
Stringtrim()
Returns a copy of the string, with leading and trailing whitespace omitted.
staticStringvalueOf(booleanb)
Returns the string representation of thebooleanargument.
staticStringvalueOf(charc)
Returns the string representation of thecharargument.
staticStringvalueOf(char[]data)
Returns the string representation of thechararray argument.
staticStringvalueOf(char[]data, intoffset, intcount)
Returns the string representation of a specific subarray of thechararray argument.
staticStringvalueOf(doubled)
Returns the string representation of thedoubleargument.
staticStringvalueOf(floatf)
Returns the string representation of thefloatargument.
staticStringvalueOf(inti)
Returns the string representation of theintargument.
staticStringvalueOf(longl)
Returns the string representation of thelongargument.
staticStringvalueOf(Objectobj)
Returns the string representation of theObjectargument.

Versión Español:

Resumen Método
charcharAt(int index)
Devuelve el carácter en el índice especificado.
intcompareTo(Objecto)
Compara esta string a otro objeto.
intcompareTo(CadenaanotherString)
Compara dos cadenas lexicográfica.
intcompareToIgnoreCase(Cadenastr)
Compara dos cadenas lexicográfica, haciendo caso omiso de las diferencias de caso.
Stringconcat(Cadenastr)
Concatena la cadena especificada al final de esta cadena.
booleancontentEquals(StringBuffersb)
Devuelveverdaderosi y sólo si estastringrepresenta la misma secuencia de caracteres como la especificadaStringBuffer.
static StringcopyValueOf(char [] data)
Devuelve una cadena que representa la secuencia de caracteres en la matriz especificada.
static StringcopyValueOf(char [] datos, int desplazamiento, int count)
Devuelve una cadena que representa la secuencia de caracteres en la matriz especificada.
booleanendsWith(Cadenasufijo)
Comprueba si la cadena termina con el sufijo especificado.
booleanequals(ObjectunObjeto)
Compara esta cadena para el objeto especificado.
booleanequalsIgnoreCase(CadenaanotherString)
Compara esta stringa otrastring, haciendo caso omiso de las consideraciones del caso.
byte []getBytes()
Codifica lastringen una secuencia de bytes utilizando charset por defecto de la plataforma, almacenando el resultado en una nueva matriz de bytes.
byte []getBytes(CadenacharsetName)
Codifica lastringen una secuencia de bytes mediante el juego de caracteres con nombre, almacenando el resultado en una nueva matriz de bytes.
vacíogetChars(int srcBegin, int srcEnd, char [] dst, int dstBegin)
Copias caracteres de esta cadena en la matriz de caracteres de destino.
inthashCode()
Devuelve un código hash para esta cadena.
intindexOf(int ch)
Devuelve el índice dentro de esta cadena de la primera aparición del carácter especificado.
intindexOf(int ch, int fromIndex)
Devuelve el índice dentro de esta cadena de la primera aparición del carácter especificado, comenzando la búsqueda en el índice especificado.
intindexOf(Cadenastr)
Devuelve el índice dentro de esta serie de la primera ocurrencia de la subcadena especificada.
intindexOf(Cadenastr, int fromIndex)
Devuelve el índice dentro de esta serie de la primera ocurrencia de la subcadena especificada, comenzando en el índice especificado.
Stringintern()
Devuelve una representación canónica para el objeto de cadena.
intlastIndexOf(int ch)
Devuelve el índice dentro de esta cadena de la última aparición del carácter especificado.
intlastIndexOf(int ch, int fromIndex)
Devuelve el índice dentro de esta cadena de la última aparición del carácter especificado, buscando hacia atrás, empezando por el índice especificado.
intlastIndexOf(Cadenastr)
Devuelve el índice dentro de esta cadena de la ocurrencia más a la derecha de la subcadena especificada.
intlastIndexOf(Cadenastr, int fromIndex)
Devuelve el índice dentro de esta cadena de la última aparición de la subcadena especificada, buscando hacia atrás, empezando por el índice especificado.
intlength()
Devuelve la longitud de esta cadena.
booleanregionMatches(ignoreCase boolean, int Tdesplazamiento,string otra, int ooffset, int len)
Comprueba si dos regiones de cadenas son iguales.
booleanregionMatches(int Tdesplazamiento,Cadenaotra, int ooffset, int len)
Comprueba si dos regiones de cadenas son iguales.
Stringreplace(char oldChar, char newChar)
Devuelve una nueva cadena resultante de reemplazar todas las apariciones deoldCharen esta cadena connewChar.
booleanstartsWith(Cadenaprefijo)
Comprueba si la cadena comienza con el prefijo especificado.
booleanstartsWith(Cadenaprefijo, int Tdesplazamiento)
Comprueba si la cadena comienza con el prefijo especificado a partir de un índice determinado.
CharSequencesubsecuencia(int beginIndex, int endIndex)
Devuelve una nueva secuencia de caracteres que es una subsecuencia de esta secuencia.
Stringsubstring(int beginIndex)
Devuelve una nueva cadena que es una subcadena de esta cadena.
Stringsubstring(int beginIndex, int endIndex)
Devuelve una nueva cadena que es una subcadena de esta cadena.
char []ToCharArray()
convierte esta cadena a una nueva matriz de caracteres.
StringtoLowerCase()
Convierte todos los personajes de estastringa minúsculas utilizando las reglas de la configuración regional predeterminada.
StringtoLowerCase(Localelocale)
Convierte todos los personajes de estastringa minúsculas utilizando las reglas de lo dadoLocale.
StringtoString()
Este objeto (que ya es una cadena!) es en sí regresaron.
StringtoUpperCase()
Convierte todos los personajes de estastringa mayúsculas utilizando las reglas de la configuración regional predeterminada.
StringtoUpperCase(Localelocale)
Convierte todos los personajes de estastringa mayúsculas utilizando las normas de la dadaLocale.
Stringtrim()
Devuelve una copia de la cadena, con el espacio inicial y final se omite.
static StringvalueOf(boolean b)
Devuelve la representación de cadena delbooleanargumento.
static StringvalueOf(char c)
Devuelve la representación de cadena delcharargumento.
static StringvalueOf(char [] data)
Devuelve la representación de cadena delcharargumento de matriz.
static StringvalueOf(char [] datos, int desplazamiento, int count)
Devuelve la representación de cadena de una submatriz específica delcharargumento de matriz.
static StringvalueOf(double d)
Devuelve la representación de cadena deldobleargumento.
static StringvalueOf(float f)
Devuelve la representación de cadena delflotadorargumento.
static StringvalueOf(int i)
Devuelve la representación de cadena delintargumento.
static StringvalueOf(long l)
Devuelve la representación de cadena de lalargadiscusión.
static StringvalueOf(Objectobj)
Devuelve la representación de cadena delobjetoargumento.

fuente:oracle.com

personal accident attorney asterisk call center software Mesothelioma Law Firm Service business software uk homeowner loans meso lawyer Online Criminal Justice Degree Best Criminal Lawyers in Arizona Business finance group Best social media platforms for business Mobile casino accident attorney orange county Hard drive Data Recovery Services WordPress hosting Donate Cars Illinois Nunavut Culture Online casino illinois mesothelioma lawyer Car Insurance in South Dakota Seo services Cheap Domain Registration Hosting CAR INSURANCE QUOTES MN Bankruptcy lawyer BEST CRIMINAL LAWYER IN ARIZONA most profitable internet business donate car for tax credit Criminal lawyer Miami Live casino Online classes mesothelioma charities Cheap Auto Insurance in VA SELL ANNUITY PAYMENT DONATING USED CARS TO CHARITY Automobile Accident Attorney DONATE CAR FOR TAX CREDIT Hire php programmers Massage School Dallas Texas Casino PSYCHIC FOR FREE Webex Costs LOW CREDIT LINE CREDIT CARDS Custom Christmas cards Donate Old Cars to Charity Social media strategies florida car insurance company Personal Injury Lawyers Html email car insurance quotes Cheap auto insurance in VA Casino reviews Car Insurance Quotes MN car insurance quotes pa Php programmers for hire personal injury attorney ocala fl mesothelioma lawyer asbestos cancer lawsuit Asbestos Lung Cancer Make money online Australia Tech school Computer science classes online injury lawyers west palm beach WORLD TRADE CENTER FOOTAGE Social media examiner Forensics Online Course life insurance quotes MORTGAGE ADVISER DUI lawyer cash out structured settlement domain registration yahoo Business Voip Solutions Hire php developers webex costs Dwi lawyer STRUCTURED ANNUITY SETTLEMENT NUNAVUT CULTURE Mortgage Adviser Social media management google affiliate Criminal lawyer Business management software Mortgage Futuristic Architecture utah mesothelioma lawyer mesothelioma care Criminal defense lawyer sell annuity payment structured settlement company Dedicated Hosting Dedicated Server Hosting Hire php developer structured settlement buyer personal injury attorney springfield mo Online Motor Insurance Quotes Donate Your Car for Kids Php programmers car accident lawyers Car Insurance Quotes Colorado Seo companies New social media platforms Car Insurance Companies Social media tools selling annuity Social media platforms for business DONATING A CAR IN MARYLAND DONATE YOUR CAR SACRAMENTO Custom WordPress theme designer mesotheolima Best Seo company small business administration sba Best social media platforms refinance with bad credit mesothelioma attorney florida Seo company Online Christmas cards adverse remortgage DONATE YOUR CAR FOR MONEY event management security WordPress themes for designers car crash attorneys Proud Italian cook PHD on Counseling Education Donate car for tax credit HOLLAND MICHIGAN COLLEGE Photo Christmas cards CAR INSURANCE QUOTES PA Better conferencing calls Psd to WordPress Donate your car Sacramento Italian cooking school CHEAP DOMAIN REGISTRATION HOSTING VIRTUAL DATA ROOMS virtual data rooms Motor Replacements bowne virtual data room Holland Michigan College selling a structured settlement Social media platforms truck accident attorney texas Christmas cards peritoneal mesothelioma Psd to html Donate Car for Tax Credit structured settlement need cash now WordPress theme designers Adobe illustrator classes mesothelioma Car insurance quotes pa MOTOR REPLACEMENTS baltimore mesothelioma attorneys Learning adobe illustrator Data Recovery Raid fast cash for house Dallas mesothelioma attorneys Social media campaigns Donate Car to Charity California Massage school Dallas Texas Donate Cars in MA MESOTHELIOMA LAW FIRM domains yahoo Donate Your Car Sacramento lawsuit mesothelioma auto accident attorney Torrance How to Donate A Car in California motorcycle accident attorney sacramento Sell Annuity Payment Asbestos Lawyers best consolidation loan student mesothelioma suit Structures Annuity Settlement hosted predictive dialers Motor Insurance Quotes paperport promotional code Annuity Settlements Dayton Freight Lines Register free domains Donate a Car in Maryland injury lawyers Criminal Defense Attorneys Florida Donating Used Cars to Charity sell my structured settlement Donating a Car in Maryland Motor replacements Donating used cars to charity best structured settlement companies CAR ACCIDENT LAWYERS Email bulk service Car Insurance Quotes Utah motorcycle lawyer los angeles Life Insurance Co Lincoln illinois law lemon personal injury attorney torrance mesothelioma attorney directory Online Colleges mesothelioma lawyer dallas Cheap Car Insurance for Ladies Paperport Promotional Code Dayton freight lines Online Classes World Trade Center Footage emergency response plan ppt Psychic for Free DONATE CARS ILLINOIS Register Free Domains asbestos lawyers home phone internet bundle Auto Mobile Shipping Quote Low Credit Line Credit Cards DAYTON FREIGHT LINES Dallas Mesothelioma Attorneys Forensics online course Donate your Car for Money Car Accident Lawyers Met Auto Online motor insurance quotes mesothelioma attorney illinois Home Phone Internet Bundle NEUSON Email Bulk Service structered settlement Business VOIP Solutions motorcycle accident lawyer san diego Forex Trading Platform PHD IN COUNSELING EDUCATION Neuson Car Insurance Quotes PA Royalty Free Images Stock mortgage adviser california law lemon domain name yahoo structured settlement brokers structure settlements mesothelioma symptoms phd in counseling education Cheap Car Insurance in Virginia motor replacements Better Conference Calls Hard drive data recovery services car insurance quotes colorado Car Donate Virtual Data Rooms anti spam exchange server Online College Course Auto Accident Attorney new mexico mesothelioma lawyer DONATE A CAR IN MARYLAND DONATE CARS IN MA buy structured settlements cheap auto insurance in va DONATE YOUR CAR FOR KIDS Best criminal lawyer in Arizona Car Insurance Quotes Nunavut culture

No hay comentarios:

Publicar un comentario