casing/casing.py
def detect(var):
    """
    Function that will detect the casing of the input variable.
    
    :param var: Variable to detect the casing
    :type var: :py:class:`str`
    
    :returns: **case**: (:py:class:`str`) - Names of avalaible cases of this module
    
    :Example: Import the module and run the function with the variable to detect.
    
    .. code-block:: python
        :linenos:
    
        import casing
        print(casing.detect("stringToDetect"))
        >>> "camel"
    """
    var_list = analyze(var)
    for fct in getcases():
        case = fct[:-len("case")]
        result = transform(var, case)   
        if result == var:
            break
    else:
        case = "unknow"
    return case

    Function that will detect the casing of the input variable.
    
    :param var: Variable to detect the casing
    :type var: :py:class:`str`
    
    :returns: **case**: (:py:class:`str`) - Names of avalaible cases of this module
    
    :Example: Import the module and run the function with the variable to detect.
    
    .. code-block:: python
        :linenos:
    
        import casing
        print(casing.detect("stringToDetect"))
        >>> "camel"
    
Function that will detect the casing of the input variable.
Function that will detect the casing of the input variable .
def detect(var):
    var_list = analyze(var)
    for fct in getcases():
        case = fct[:-len("case")]
        result = transform(var, case)   
        if result == var:
            break
    else:
        case = "unknow"
    return case
def detect ( var ) : var_list = analyze ( var ) for fct in getcases ( ) : case = fct [ : - len ( "case" ) ] result = transform ( var , case ) if result == var : break else : case = "unknow" return case
Function that will detect the casing of the input variable.
Function that will detect the casing of the input variable .
"""
    Function that will detect the casing of the input variable.
    
    :param var: Variable to detect the casing
    :type var: :py:class:`str`
    
    :returns: **case**: (:py:class:`str`) - Names of avalaible cases of this module
    
    :Example: Import the module and run the function with the variable to detect.
    
    .. code-block:: python
        :linenos:
    
        import casing
        print(casing.detect("stringToDetect"))
        >>> "camel"
    """
case**: (:py:class:`str`) - Names of avalaible cases of this module
case ** : ( : py : class : ` str ` ) - Names of avalaible cases of this module
var
Variable to detect the casing
Variable to detect the casing
Example
Import the module and run the function with the variable to detect.
code-block:: python
:linenos.

import casing
print(casing.detect("stringToDetect"))
>>> "camel"
Import the module and run the function with the variable to detect . code - block :: python : linenos . import casing print ( casing . detect ( " stringToDetect " )) >>> " camel "