Licensing – Aspose.SVG for Python via .NET
Evaluation Version Limitations
Aspose.SVG for Python via .NET is software that developers can try before purchasing. A free evaluation version of Aspose.SVG for Python via .NET can be downloaded from the downloads section of Aspose’s website at: Download Aspose.SVG Python Library.
Limitation
The evaluation version of Aspose.SVG is the same as the purchased one. By incorporating a few lines of code to apply the license, the trial version simply transitions to a licensed version. The evaluation version provides all the features except the following:
- Watermark is added to the output files.
- Only the first four pages of the SVG document can be converted.
- Only 50% of SVG Document’s nodes will be saved during serialization.
If you want to try Aspose.SVG without evaluation limitations, request a 30 day temporary license. Please refer to How to get a Temporary License? for more information.
Apply License using File or Stream Object
The license can be loaded from a file or stream object. Aspose.SVG for Python via .NET will try to find the license in the following locations:
- Explicit path.
- The folder that contains Aspose.SVG.dll.
- The folder that contains the assembly that called Aspose.SVG.dll.
- The folder that contains the entry assembly (your .exe).
- An embedded resource in the assembly that called Aspose.SVG.dll.
The license filename is not limited to “Aspose.SVG.Python.NET.lic”. Feel free to rename it as you wish and use that name when applying the license in your application.
Loading a License from File
The easiest way to apply a license is to put the license file in the same folder as the Aspose.SVG.dll file and specify just the file name without a path. You can create a license
folder and place the license file there. The set_license()
method then gets the path to the license file.
Example:
1# Initialize license object
2lic = License()
3
4# Set license from file
5lic.set_license("./license/Aspose.SVG.Python.via.NET.lic")
6
7print("License set successfully.")
Apply Metered License
Aspose.SVG for Python via .NET API allows developers to apply the metered license. It is a new licensing mechanism. The new licensing mechanism will be used along with the existing licensing method. Those customers who want to be billed based on the usage of the API features can use the metered licensing. For more details, please refer to Metered Licensing FAQ section.
After completing all the necessary steps to obtain this type of license, you will receive the keys, not the license file. A new class Metered has been added to apply the metered key. This code example demonstrates how to set metered public and private keys:
1# Create an instance of the Metered class
2metered = Metered()
3
4# Set the public and private keys for metered licensing
5public_key = "your-public-key"
6private_key = "your-private-key"
7
8# Apply the metered license
9metered.set_metered_key(public_key, private_key)
Using Multiple Aspose Products
When employing multiple Aspose products within your application, for example Aspose.SVG and Aspose.HTML, consider the following helpful guidelines:
- Apply the License for Each Aspose Product Individually: Even if you possess a single license file encompassing all components, such as “Aspose.Total.lic”, ensure to invoke
set_license()
separately for each Aspose product integrated into your application. - Employ the Fully Qualified License Class Name: Each Aspose product features its own License class within its respective namespace. For instance, Aspose.SVG utilizes the
aspose.svg.License
, and Aspose.HTML utilizes theaspose.html.License
class. Utilizing the fully qualified class name aids in avoiding ambiguity regarding which license corresponds to which product.