Component naming

Post

Posted
Rating:
#1 (In Topic #2048)
Avatar
Trainee
supertunaman is in the usergroup ‘Trainee’
Hello!

I thought it would be fun to write a gambas component exposing the GPGME library. My question is, should I name this `gb.crypto.gpgme`, or simply `gb.gpgme`?

Here's why I ask – `gb.crypto` is a fairly limited library. I don't expect that my gpgme component will even have it as a dependency. However, if I was looking at a component list looking for a GPG library, I would probably check the ones labeled "crypto" first. Therefore, it makes sense to me that it would be named, `gb.crypto.gpgme`.

Any advice, or other guidelines on naming components, would be appreciated!

Andrew
Online now: No Back to the top

Post

Posted
Rating:
#2
Avatar
Trainee
supertunaman is in the usergroup ‘Trainee’
Noticed this typo too late – I meant `gb.crypt` in all instances, not `gb.crypto`.
Online now: No Back to the top

Post

Posted
Rating:
#3
Avatar
Administrator
gbWilly is in the usergroup ‘unknown’
gbWilly leads the usergroup ‘GambOS Contributor’
gbWilly is in the usergroup ‘Blogger’

supertunaman said

Any advice, or other guidelines on naming components, would be appreciated!

If you want to develop a component for yourself, you can actually use any name you would like.
I, for example, have written a component to interface libvlc and provide some controls, currently for my own use.
I named it gbwilly.vlc.form, but I can always rename it to gb.vlc.from, if ever added to official.

post.png

gbwilly.vlc.form instead of gb.wvl.form

The gb.<componentname> is the official gambas components convention.
If you want to write one of those you will need to:
1. discuss the naming on the gambas mailing list (subscribe here to user mailing list).
2. meet a certain convention in your approach and code
3. be willing to maintain the component

Some reads on the topic:
How To Program Components In C/C++
How To Program Components/Controls In Gambas
How To Interface Gambas With External Libraries

Enjoy… :thumbs:



 

gbWilly
- Gambas Dutch translator
- Gambas wiki content contributor
- Gambas debian/ubuntu package recipe contributor
- GambOS, a distro for learning Gambas and more…
- Gambas3 Debian/Ubuntu repositories


… there is always a Catch if things go wrong!
Online now: No Back to the top
1 guest and 0 members have just viewed this.