On Fri, Jul 10, 2020 at 8:29 PM Davide Perini <[email protected]> wrote:
>
> this simple line of code:
>
> mapper.writeValue(new File(path + File.separator + "FastScreenCapture.yaml"), 
> config);
>
>
> serialized my config object into a yaml file correclty.
>
> If I try to use the java modules by simply adding this to the project in a 
> module-info.java
>
> module FastScreenCapture {
>
>     requires java.base;
>     requires java.desktop;
>     requires org.freedesktop.gstreamer;
>     requires static lombok;
>     requires org.mapstruct.processor;
>     requires com.sun.jna.platform;
>     requires com.sun.jna;
>     requires nrjavaserial;
>     requires org.eclipse.paho.client.mqttv3;
>     requires com.fasterxml.jackson.dataformat.yaml;
>     requires com.fasterxml.jackson.databind;
>     requires com.fasterxml.jackson.core;
>     requires com.fasterxml.jackson.datatype.jsr310;
>
> }
>
>
> jackson write an empty file.
>
> any help?
> why the module-info.java file should create this problem?

I don't have any good ideas based just on this piece of information
(esp. without value classes, which seem to
use Lombok for processing too). But maybe others have experience on this?
Inclusion of module-info will likely enable access/visibility checks
that are not used without that,
so ... perhaps you also need to add

   requires com.fasterxml.jackson.annotation;

in case properties are not otherwise visible (no public getters)?

-+ Tatu +-

-- 
You received this message because you are subscribed to the Google Groups 
"jackson-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jackson-user/CAL4a10gidLS_T7kdVqfxd5fgp4niHKQGyVPRbTU89SxO323JLA%40mail.gmail.com.

Reply via email to