JOOMLA中国
  • Joomla中国首页
  • 社区
  • 教程
  • 应用市场
  • B计划
Joomla! Framework TM
  • Namespace
  • Class
  • Tree
  • Deprecated

Namespaces

  • Composer
    • Autoload
  • Joomla
    • Application
      • Cli
        • Output
          • Processor
      • Web
    • Data
    • DI
      • Exception
    • Event
    • Filter
    • Input
    • Ldap
    • Registry
      • Format
    • Session
      • Storage
    • String
    • Uri
    • Utilities
  • None
  • PasswordCompat
    • binary
  • PHP
  • Psr
    • Log
  • Symfony
    • Component
      • Yaml
        • Exception
    • Polyfill
      • Util

Classes

  • Inflector
  • Normalise
  • String
  • StringHelper

Class Normalise

Joomla Framework String Normalise Class

Abstract
Namespace: Joomla\String
Since: 1.0
Located at vendor/joomla/string/src/Normalise.php

Methods summary

public static string
# fromCamelCase( string $input, boolean $grouped = false )

Method to convert a string from camel case.

Method to convert a string from camel case.

This method offers two modes. Grouped allows for splitting on groups of uppercase characters as follows:

"FooBarABCDef" becomes array("Foo", "Bar", "ABC", "Def") "JFooBar" becomes array("J", "Foo", "Bar") "J001FooBar002" becomes array("J001", "Foo", "Bar002") "abcDef" becomes array("abc", "Def") "abc_defGhi_Jkl" becomes array("abc_def", "Ghi_Jkl") "ThisIsA_NASAAstronaut" becomes array("This", "Is", "A_NASA", "Astronaut")) "JohnFitzgerald_Kennedy" becomes array("John", "Fitzgerald_Kennedy"))

Non-grouped will split strings at each uppercase character.

Parameters

$input
string - $input The string input (ASCII only).
$grouped
boolean - $grouped Optionally allows splitting on groups of uppercase characters.

Returns

string - The space separated string.

Since

1.0
public static string
# toCamelCase( string $input )

Method to convert a string into camel case.

Method to convert a string into camel case.

Parameters

$input
string - $input The string input (ASCII only).

Returns

string - The camel case string.

Since

1.0
public static string
# toDashSeparated( string $input )

Method to convert a string into dash separated form.

Method to convert a string into dash separated form.

Parameters

$input
string - $input The string input (ASCII only).

Returns

string - The dash separated string.

Since

1.0
public static string
# toSpaceSeparated( string $input )

Method to convert a string into space separated form.

Method to convert a string into space separated form.

Parameters

$input
string - $input The string input (ASCII only).

Returns

string - The space separated string.

Since

1.0
public static string
# toUnderscoreSeparated( string $input )

Method to convert a string into underscore separated form.

Method to convert a string into underscore separated form.

Parameters

$input
string - $input The string input (ASCII only).

Returns

string - The underscore separated string.

Since

1.0
public static string
# toVariable( string $input )

Method to convert a string into variable form.

Method to convert a string into variable form.

Parameters

$input
string - $input The string input (ASCII only).

Returns

string - The variable string.

Since

1.0
public static string
# toKey( string $input )

Method to convert a string into key form.

Method to convert a string into key form.

Parameters

$input
string - $input The string input (ASCII only).

Returns

string - The key string.

Since

1.0

Magic methods summary

Joomla! Framework TM API documentation generated by ApiGen 2.8.0
Joomla!® and Joomla! Framework™ are trademarks of Open Source Matters, Inc. in the United States and other countries.