Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
wiki:savant_useful_information:libraries_and_frameworks [2016/08/09 02:27]
benp
wiki:savant_useful_information:libraries_and_frameworks [2016/08/09 07:09] (current)
benp
Line 1: Line 1:
 ====== Libraries and Frameworks ====== ====== Libraries and Frameworks ======
 +
 +The documentation of the libraries and frameworks herein is largely concerned with how they imported and used in Python. That being said, much of the information recorded here could easily be transposed into other languages that are able to make direct use of shared C/​C++/​Objective-C objects.
 +
 +To import a Savant provided Framework into a Python program intended for execution on a Mac, use the following code:
 +
 +<​code>​
 +try:
 + objc.loadBundle("​avComponentXML",​ globals(), bundle_path=objc.pathForFramework(u'/​Users/​benp/​Library/​Frameworks/​avComponentXML.framework'​))
 +except ImportError:​
 + print "​failed to import Framework"​
 +</​code>​
 +
 +For a Python script intended for use on a Smarthost, use:
 +<​code>​
 +
 +</​code>​
 +
  
   * [[wiki:​savant_useful_information:​libraries_and_frameworks:​avcomponentxml|]]   * [[wiki:​savant_useful_information:​libraries_and_frameworks:​avcomponentxml|]]
   * [[wiki:​savant_useful_information:​libraries_and_frameworks:​componentservicerulesxml|]]   * [[wiki:​savant_useful_information:​libraries_and_frameworks:​componentservicerulesxml|]]

Log In