parameters: (parameter)
return_statement: return parameter_dict
docstring: Converts parameter to an IDS compliant dictionary, handling both value and restrictions.
  
      :return: Xmlschema compliant dictionary.
      :rtype: dict
docstring_summary: Converts parameter to an IDS compliant dictionary, handling both value and restrictions.
docstring_tokens: Converts parameter to an IDS compliant dictionary handling both value and restrictions .
function: def parameter_asdict(parameter):
      """Converts parameter to an IDS compliant dictionary, handling both value and restrictions.
  
      :return: Xmlschema compliant dictionary.
      :rtype: dict
      """
      if isinstance(parameter, str):
          parameter_dict = {"simpleValue": parameter}
      elif isinstance(parameter, restriction):
          parameter_dict = {"xs:restriction": [parameter.asdict()]}
      elif isinstance(parameter, list):
          restrictions = {"@base": "xs:" + parameter[0].base}
          for p in parameter:
              x = p.asdict()
              restrictions[list(x)[1]] = x[list(x)[1]]
          parameter_dict = {"xs:restriction": [restrictions]}
      return parameter_dict
function_tokens: def parameter_asdict ( parameter ) : if isinstance ( parameter , str ) : parameter_dict = { "simpleValue" : parameter } elif isinstance ( parameter , restriction ) : parameter_dict = { "xs:restriction" : [ parameter . asdict ( ) ] } elif isinstance ( parameter , list ) : restrictions = { "@base" : "xs:" + parameter [ 0 ] . base } for p in parameter : x = p . asdict ( ) restrictions [ list ( x ) [ 1 ] ] = x [ list ( x ) [ 1 ] ] parameter_dict = { "xs:restriction" : [ restrictions ] } return parameter_dict