parameters: (self, source_credit)
docstring: Set the quantity
docstring_summary: Set the quantity
docstring_tokens: Set the quantity
function: def setSourceCredit(self, source_credit):
      """
        Set the quantity
      """
      if source_credit in (None, ''):
        return
      try:
        source_credit = float(source_credit)
      except TypeError:
        source_credit = 0.0
      self.setCancellationAmount(source_credit < 0)
      self.setQuantity(source_credit)
function_tokens: def setSourceCredit ( self , source_credit ) : if source_credit in ( None , '' ) : return try : source_credit = float ( source_credit ) except TypeError : source_credit = 0.0 self . setCancellationAmount ( source_credit < 0 ) self . setQuantity ( source_credit )