PDA

View Full Version : Creating Plug-ins




satyam90
Mar 6, 2008, 01:19 AM
Hi, I am newbie in XCode programming. I am trying to learn how to create plugins for an application. Thereotically I understood how to create plugins.
I have gone thru copule of websites lilke http://cocoadevcentral.com/articles/000068.php and http://developer.apple.com/documentation/cocoa/conceptual/loadingcode/concepts/plugins.html
I ended up in confusion where to add the code. I couldn't trace it up.

Can any body send me some simple application or link to the plugin applications where I can easily understand? Please help me !!!!!!!!!!



kainjow
Mar 6, 2008, 08:53 AM
Which part are you stuck at?

yeroen
Mar 6, 2008, 09:18 AM
For which applications do you want to create plugins? There are as many different ways to write plugins as there are applications.

The apple developer article you linked to discussed creating plugin architectures for applications and is meant for the application developer; this is quite distinct from writing the plugins themselves.

satyam90
Mar 7, 2008, 04:16 AM
I am not able to understand at all from where to start coding to create plugins.

I am not trying to create plug-ins for already available applications.
I am trying to learn how to create an application and some plugins that I can interact from my application. And I want to be a good application developer.

I am using XCode tool, Obj C and cocoa framework.

Cromulent
Mar 7, 2008, 05:51 AM
I am not able to understand at all from where to start coding to create plugins.

I am not trying to create plug-ins for already available applications.
I am trying to learn how to create an application and some plugins that I can interact from my application. And I want to be a good application developer.

I am using XCode tool, Obj C and cocoa framework.

Which applications though? Each application has a different plug-in API. If you give us some specific information it would help.

satyam90
Mar 7, 2008, 06:27 AM
Basically I want to learn how to code a plugin.
What I am doing is creating an application where it will show a dialot that asks for a text file path. Then it has to pass the path info to plugin, where plugin will display info related to the file like, number of lines, number of words, file creation date etc.

Soulstorm
Mar 7, 2008, 08:05 AM
Basically I want to learn how to code a plugin.
What I am doing is creating an application where it will show a dialot that asks for a text file path. Then it has to pass the path info to plugin, where plugin will display info related to the file like, number of lines, number of words, file creation date etc.

The reason you are getting so vague answers is because you are asking the wrong questions.

There is no standard way of knowing how to code a plugin. A plugin is coded by taking advantage of certain features of an application. That means that the application must be coded in a way that it leaves many possibilities for extension to 3rd party developers.

In order to make an application ready to accept plugins, you must first write the application itself. You will need to invent a language yourself, or at least create global variables, classes and methods that a developer can call from your application. In other words, you will need to create an API for your application, and that's not an easy task.

You clearly don't know how difficult it is. Build your application first, and then, you will have a better idea on how to create an API that can access its low level functions and use them for plugin development.