get paramters of the currently edited function/procedure

alec

Member
Dear PLSQL Developer Team,
Dear Forum members,

I'm working to PLSQL Developer plugin which is intended to be used for logging purposes. The idea is quite simple: to have the possibility to chosse from the contextual popup menu (within a program window) various log statements such as: "log here as DEBUG", "log here as ERROR" etc. So far I succeeded to implement them without problems but I have a new challenge. I want to also implement the possibility to log the parameters of the currently edited function or procedure. The expected behavior is to place the cursor within the target function or procedure body, to choose from the contextual menu the "Log parameters here" and the plugin to extract the previously defined parameters and to build-up the corresponding log statement. The tricky part is that the function or procedure might not be compiled therefore I cannot rely to the data from the Oracle dictionary tables but as far as I could see the PLSQL Developer IDE already has this information into the "Contents section" shown into the right side of the editor window.
So, my question is: does PL/SQL Developer expose this functionality through some callback functions? And if not, are there any chances this feature to be published to the interested developers? Are there any workarounds?

Many thanks in advance,
alec.
 
There is no explicit support for this, but you can of course get the text from the editor and parse it. Would that be an option?
 
Alec,
I have done this through templates. It works well when you first set up a procedure/function, but for modifications to the parameter list I must perform manually.

Vince
 
Marco, Vinny: many thanks for the answers. Actually I'm going to take into consideration both approaches: to manually parse the text from the editor window which of course is not very handy but at least it's a valid workaround and to also setup some templates with the log entries already built.

alec.
 
Back
Top