[Yanel-dev] avalon framework
Michael Wechner
michael.wechner at wyona.com
Tue Jul 7 23:01:40 CEST 2009
Prabodh Upreti schrieb:
> Sorry, I am a little behind replying to the post.
>
> Guillaume, thanks for the info. I did not know that Avalon was dead.
>
> I was trying to basically use avalon the same way yarepuser was using
> it; mainly to read/write javabean to an xml file.
>
> I am currently just outputing the file using ObjectOutputStream and
> loading it using as a DOM object. I was just looking for a prebuilt
> functionality in the framework to read/write to the repository.
for example you can write as follows:
InputStream in = ....;
OutputStream out =
getRealm().getRepository().getNode("/foo/bar.txt").getOutputStream();
byte buffer[] = new byte[8192];
int bytesRead;
while ((bytesRead = in.read(buffer)) != -1) {
out.write(buffer, 0, bytesRead);
}
out.close();
in.close();
> I may be missing something here. Thank you.
maybe it's best if you send the part of your code where you want to
write (or read) and I am sure we will be able to help you ;-)
Cheers
Michael
>
> Prabodh
>
>
>
>
> ------------------------------------------------------------------------
> *From:* Michael Wechner <michael.wechner at wyona.com>
> *To:* yanel-development at wyona.com
> *Sent:* Tuesday, July 7, 2009 4:07:47 PM
> *Subject:* Re: [Yanel-dev] avalon framework
>
> Guillaume Déflache schrieb:
> > Hi!
> >
> > Prabodh Upreti schrieb:
> >> Hello
> >> I want to use the avalon framework in my new resource. I have added
> >
> > Why do you need it? Apache Avalon is basically dead nowadays, you
> should avoid it if possible (I know, it's still even part of Yanel's
> core but anyway).
>
> IIRC we just need some specific utilities and not the framework itself
> and I agree that we should try to get rid of it.
>
> As Guillaume was asking I think it would be good to know why you want
> to use it? Maybe we can help to provide alternatives ;-)
>
> Cheers
>
> Michael
> >
> >
> >> <dependency groupId="avalon-framework"
> artifactId="avalon-framework-api" version="4.3"/>
> >> in the dependencies.xml file. It is not detecting the necessary
> classes. I am performing an external build via ./build.sh -f
> src/contributions/resources/forgotpw/build.xml compile . Could you
> please let me know what else I should do to make it work in my local
> environment? Thank you.
> >
> > To which "artifact:dependencies" element have you added it? Make
> sure it's the one with the "maven2.resource.*" IDs, help it will
> porbably won't do much. See for example
> http://svn.wyona.com/repos/public/yanel/trunk/src/resources/user-mgmt/src/build/dependencies.xml
> which also seems to require Avalon (presumably for reading XML
> configuration files).
> >
> > Cheers,
> > Guillaume
>
> -- Yanel-development mailing list Yanel-development at wyona.com
> <mailto:Yanel-development at wyona.com>
> http://lists.wyona.org/cgi-bin/mailman/listinfo/yanel-development
>
More information about the Yanel-development
mailing list