Class/Object

fm.common.rich

RichString

Related Docs: object RichString | package rich

Permalink

final class RichString extends AnyVal

Linear Supertypes
AnyVal, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. RichString
  2. AnyVal
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new RichString(s: String)

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def capitalizeFully(delimiters: Char*): String

    Permalink

    See org.apache.commons.lang3.text.WordUtils.capitalizeFully

  6. def capitalizeFully: String

    Permalink

    See org.apache.commons.lang3.text.WordUtils.capitalizeFully

  7. def capitalizeWords(delimiters: Char*): String

    Permalink

    See org.apache.commons.lang3.text.WordUtils.capitalize

  8. def capitalizeWords: String

    Permalink

    See org.apache.commons.lang3.text.WordUtils.capitalize

  9. def getClass(): Class[_ <: AnyVal]

    Permalink
    Definition Classes
    AnyVal → Any
  10. def internOrNull: String

    Permalink

    Same as String.intern but safe for use when the string is null (i.e.

    Same as String.intern but safe for use when the string is null (i.e. it just returns null)

  11. def isBigDecimal: Boolean

    Permalink
  12. def isBoolean: Boolean

    Permalink
  13. def isByte: Boolean

    Permalink
  14. def isDouble: Boolean

    Permalink
  15. def isFloat: Boolean

    Permalink
  16. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  17. def isInt: Boolean

    Permalink
  18. def isLong: Boolean

    Permalink
  19. def isNotBigDecimal: Boolean

    Permalink
  20. def isShort: Boolean

    Permalink
  21. def lPad(length: Int, c: Char = ' '): String

    Permalink
  22. def lowerAlphaNumeric: String

    Permalink

    See fm.common.Normalize.lowerAlphaNumeric

  23. def lowerAlphaNumericWords: Array[String]

    Permalink

    See fm.common.Normalize.lowerAlphaNumericWords

  24. def pad(length: Int, c: Char = ' '): String

    Permalink
  25. def parseBigDecimal(implicit locale: Locale): Option[BigDecimal]

    Permalink
  26. def parseBoolean: Option[Boolean]

    Permalink

    Unlike toBoolean/toBooleanOption/isBoolean this method will attempt to parse a boolean value from a string.

  27. def rPad(length: Int, c: Char = ' '): String

    Permalink
  28. def replaceAll(regex: Regex, replacement: String): String

    Permalink
  29. def replaceFirst(regex: Regex, replacement: String): String

    Permalink
  30. def requireLeading(lead: String): String

    Permalink

    If this string does not start with the lead param then return a new string with it added to the start of the string

    If this string does not start with the lead param then return a new string with it added to the start of the string

    TODO: is there a better name for this?

  31. def requireTrailing(trail: String): String

    Permalink

    If this string does not ends with the trail param then return a new string with it added to the end of the string

    If this string does not ends with the trail param then return a new string with it added to the end of the string

    TODO: is there a better name for this?

  32. val s: String

    Permalink
  33. def stripAccents: String

    Permalink
  34. def stripLeading(lead: String): String

    Permalink

    If this string starts with the lead param then return a new string with lead stripped from the start

    If this string starts with the lead param then return a new string with lead stripped from the start

    NOTE: The same functionality is available in Scala's StringOps.stripPrefix

  35. def stripTrailing(trail: String): String

    Permalink

    If this string ends with the trail param then return a new string with trail stripped from the end

    If this string ends with the trail param then return a new string with trail stripped from the end

    NOTE: The same functionality is available in Scala's StringOps.stripSuffix

  36. def toBigDecimal: BigDecimal

    Permalink
  37. def toBigDecimalOption: Option[BigDecimal]

    Permalink
  38. def toBigInteger: BigInteger

    Permalink
  39. def toBigIntegerOption: Option[BigInteger]

    Permalink
  40. def toBlankOption: Option[String]

    Permalink

    If the string is blank returns None else Some(string)

  41. def toBooleanOption: Option[Boolean]

    Permalink
  42. def toByteOption: Option[Byte]

    Permalink
  43. def toDoubleOption: Option[Double]

    Permalink
  44. def toFile: File

    Permalink

    A shortcut for "new java.io.File(s)"

  45. def toFloatOption: Option[Float]

    Permalink
  46. def toIntOption: Option[Int]

    Permalink
  47. def toLongOption: Option[Long]

    Permalink
  48. def toShortOption: Option[Short]

    Permalink
  49. def toString(): String

    Permalink
    Definition Classes
    Any
  50. def truncate(length: Int, omission: String = ""): String

    Permalink

    Truncate the string to length if it is currently larger than length.

    Truncate the string to length if it is currently larger than length.

    Note: The resulting string will not be longer than length. (i.e the omission counts towards the length)

    length

    The length to truncate the string to

    omission

    If the string is truncated then add this to the end (Note: The resulting still will be at most length)

  51. def urlName: String

    Permalink

    See fm.common.Normalize.name

Inherited from AnyVal

Inherited from Any

Ungrouped