Skip to content
Snippets Groups Projects
Commit f9050f24 authored by Reinhold Kainhofer's avatar Reinhold Kainhofer
Browse files

Add API doc

parent ab939ef2
No related branches found
No related tags found
No related merge requests found
RulesShippingFramework:
=======================
API functions:
~~~~~~~~~~~~~~
-) setup() // Used in the plugin's constructor
-) registerCallback($callback, $func)
-) warning($text, $args...)
-) debug($text)
-) parseRuleSyntax($rulestring, $countries, $ruleinfo)
-) checkConditions ($cart, $method)
-) getCosts($cart, $method) // The central function to calculate the shipping cost
-) getRuleName($methodid)
-) getRuleVariables($methodid)
-) filterProducts($products, $conditions) // Used in the Rule's evaluateScoping
-) registerScopings($scopings)
-) getScopings()
E-commerce specific functions (to be overridden in child classes!):
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-) printWarning($message) // $message already translated!
-) debug($message)
-) __($string) // or use the translate callback for your own function!
-) getCustomFunctions()
-) addPluginCartValues($cart, $products, $method, &$values)
-) getOrderArticles($cart, $products, $method)
-) getOrderProducts ($cart, $products, $method)
-) getOrderDimensions ($cart, $products, $method)
-) getOrderWeights ($cart, $products, $method)
-) getOrderListProperties ($cart, $products, $method)
-) getOrderAddress ($cart, $method)
-) getOrderPrices ($cart, $products, $method)
-) filterProducts($products, $conditions) // Used in the Rule's evaluateScoping
-) getMethodId ($method)
-) getMethodName ($method)
-) setMethodCosts($cart, $method, $match, $costs) // Potentially assign system-specific variables to the $method
Callback functions:
~~~~~~~~~~~~~~~~~~~
-) translate($message)
-) initRule($framework, $rulestring, $countries, $ruleinfo)
-) addCustomCartValues ($cart, $products, $method, &$values)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment