[izpack-devel] How can I get the installer's variables in myownclass in the executeclass

RAMOS lionel calimucho at gmail.com
Tue Jan 8 16:53:37 CET 2008


Hi klaus,

Thanks to help me.
I see your VariableSubstitutor. It's intersting to use and very simple.

VariableSubstitutor vs = *new* VariableSubstitutor(idata.getVariables());
Maybe, I'll use it. My class that I want to do is a class how take in
paramaters some files.
The class took the files and replace all my variables in there.
Why I don't use the installPanel for it because I put a variable like :
<variables>
  <variable name="test" value="${TomcatVersion}:${ENV[ApplicationServer.type
]}"/>
<variables>

and in my files I put juste ${test} on it and he replace juste with
${TomcatVersion}:${ENV[ApplicationServer.type]}"

So I've this idea to create a class and to call a ProcessPanel before the
installPanel.

Do you think it's a good idea?
And I'm sorry, I don't understand the custom action concept....

Can you explain me?

Regards,

-- 
Lionel
On Jan 8, 2008 9:44 AM, Bartz, Klaus <Klaus.Bartz at coi.de> wrote:

>  Hi, Lionel,
> no problem.
> I use InstallData.getVariables() more than once in my own custom actions
> (InstallerListener). Often in a call to VariableSubstitutor. May be that
> what you need. If you use Eclipse with IzPack sources you can simple find
> the calls and use them as example.
> Do you know the custom action concept? May be it is also a way to solve
> your requirements.
>
> Cheers
>
> Klaus
>
>  -----Original Message-----
> *From:* izpack-devel-bounces at lists.berlios.de [mailto:
> izpack-devel-bounces at lists.berlios.de] *On Behalf Of *RAMOS lionel
> *Sent:* Monday, January 07, 2008 5:09 PM
> *To:* izpack-devel at lists.berlios.de
>  *Subject:* Re: [izpack-devel] How can I get the installer's variables in
> myownclass in the executeclass
>
>   Hi Klaus,
>
>
> Oh jesus,
>
> I haven't seen her...
>  Thanks for replying me quickly,
> sorry I must buy other glasses I think.
>
> I'll used installData for the same things that used the <parsable> tag in
> the main xml.
>
> It is a good idea?
>
> Regards
>
>
>
> --
> Lionel
>
> On Jan 7, 2008 4:13 PM, Bartz, Klaus <Klaus.Bartz at coi.de> wrote:
>
> >  Hi  Lionel,
> >
> > long time ago I have had also such a problem. Since them, a getInstance
> > method for the install data exist.
> >
> > Vars you can access like
> >
> > String javaPath = AutomatedInstallData.*getInstance*().getVariable("
> > MyVar");
> >
> > Cheers
> >
> > Klaus
> >
> >  -----Original Message-----
> > *From:* izpack-devel-bounces at lists.berlios.de [mailto:
> > izpack-devel-bounces at lists.berlios.de] *On Behalf Of *RAMOS lionel
> > *Sent:* Monday, January 07, 2008 3:30 PM
> > *To:* izpack-devel at lists.berlios.de
> > *Subject:* [izpack-devel] How can I get the installer's variables in my
> > ownclass in the executeclass
> >
> > Hi guys,
> >
> > I'm starting developping my own class who'll be called in ProcessPanel
> > with the <executeclass> tag.
> > But I've no idea how can I have all the installer's variables in my
> > class ...
> > I've seen in the other panel that you give installData in parameter but
> > when you call with executeclass.
> > The executeclass call a method run(AbstractUIProcessHandler handler,
> > String[] args) so I don't have the installData.
> >
> > Any idea?
> >
> > Thx in advance,
> >
> > Regards
> >
> > P.S. : Sorry for my bad english...
> >
> >
> > --
> > Lionel
> >
> >
> > _______________________________________________
> > izpack-devel mailing list
> > izpack-devel at lists.berlios.de
> > https://lists.berlios.de/mailman/listinfo/izpack-devel
> >
> >
> _______________________________________________
> izpack-devel mailing list
> izpack-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.berlios.de/pipermail/izpack-devel/attachments/20080108/5aa484ed/attachment.html 


More information about the izpack-devel mailing list