473,388 Members | 1,526 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Python Based API

Hi,

I work on a project that is built entirely using python and Tkinter.
We are at the point where we would like to give access to our
functionality to others via some sort of API. People who would use
our API develop in all kinds of languages from C/C++ to Pascal.

Ideas that come to mind that allow us to build such an API are:

1) Require others to imbed the python interpreter via the c API to be
able to utilize our functionality.
2) Build an XML RPC interface around our code.
3) Rewrite our code base in C/C++, which should make it accessible to
all modern languages.

I'm looking for more and potentially better ideas that will allow us
to offer an API to our customers without having to throw away or redo
a lot of the python code that we have already written.

Thanks in advance,
Dean

Apr 1 '07 #1
2 1177
De**********@gmail.com wrote:
Hi,

I work on a project that is built entirely using python and Tkinter.
We are at the point where we would like to give access to our
functionality to others via some sort of API. People who would use
our API develop in all kinds of languages from C/C++ to Pascal.

Ideas that come to mind that allow us to build such an API are:

1) Require others to imbed the python interpreter via the c API to be
able to utilize our functionality.
2) Build an XML RPC interface around our code.
3) Rewrite our code base in C/C++, which should make it accessible to
all modern languages.

I'm looking for more and potentially better ideas that will allow us
to offer an API to our customers without having to throw away or redo
a lot of the python code that we have already written.

Thanks in advance,
Dean
IMHO the simplest solution is XML RPC, and unless you have huge data to
transmit or time constraint, it may be enough.
Apr 1 '07 #2
De**********@gmail.com wrote:
Hi,

I work on a project that is built entirely using python and Tkinter.
We are at the point where we would like to give access to our
functionality to others via some sort of API. People who would use
our API develop in all kinds of languages from C/C++ to Pascal.

Ideas that come to mind that allow us to build such an API are:

1) Require others to imbed the python interpreter via the c API to be
able to utilize our functionality.
2) Build an XML RPC interface around our code.
3) Rewrite our code base in C/C++, which should make it accessible to
all modern languages.

I'm looking for more and potentially better ideas that will allow us
to offer an API to our customers without having to throw away or redo
a lot of the python code that we have already written.

Thanks in advance,
Dean
You don't say what your operating system is, so I'll give an answer in
case it is Windows:

I went through something similar recently and decided that writing a COM
wrapper around my Python API was the best answer (and it turned out to
be pretty easy). I was easily able to call from VB, Delphi and Python
COM. I haven't tried C/C++ yet, but expect no problems. I think COM is
now the way to go (unless you do .NET).

-Larry

Apr 2 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: bezeee | last post by:
At my work we are in the process of building a tool to test an XML based API. Basically, XML in and XML out over http. Currently, there are two engines that do all of the schema validations, xml...
13
by: Ajay | last post by:
hi! can you call a Python application from a Java program? does this require any additional package to be installed? thanks cheers
54
by: seberino | last post by:
Many people I know ask why Python does slicing the way it does..... Can anyone /please/ give me a good defense/justification??? I'm referring to why mystring gives me elements 0, 1, 2 and 3...
29
by: 63q2o4i02 | last post by:
Hi, I'm interested in using python to start writing a CAD program for electrical design. I just got done reading Steven Rubin's book, I've used "real" EDA tools, and I have an MSEE, so I know what...
28
by: H J van Rooyen | last post by:
Hi, I want to write a small system that is transaction based. I want to split the GUI front end data entry away from the file handling and record keeping. Now it seems almost trivially easy...
7
by: Chris | last post by:
I have an database containing lots of numerical data. I want to write a browser based interface that will allow selection of various key parameters and yield tables, plots and/or printouts of the...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.