Deserializing ListMap with lift-json

조회수 17회
읽지 않은 첫 메시지로 건너뛰기

Joe Barnes

읽지 않음,
2016. 2. 2. 오후 2:54:0916. 2. 2.
받는사람 Lift
Has anyone successfully written a ListMap deserializer for lift-json?  We tried writing our own Serializer, but lift-json keeps expecting our case class's constructor to have a Map.  I think it's because ListMap is a child type of Map, so lift-json is finding map before it finds our custom deserialization case.

Joe

Antonio Salazar Cardozo

읽지 않음,
2016. 2. 2. 오후 10:39:3216. 2. 2.
받는사람 Lift
That sounds slightly weird, but perhaps adding a type hint would help?
Thanks,
Antonio

Joe Barnes

읽지 않음,
2016. 2. 3. 오전 6:20:2616. 2. 3.
받는사람 lif...@googlegroups.com
I'd like to avoid changing the serialization of the object with a type hint... but perhaps I can no-op the serialization and use only the name of the field on deserialization?  I'll have to look today when I get back to the code.

Joe


--
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code

---
You received this message because you are subscribed to a topic in the Google Groups "Lift" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/liftweb/IyqS-w52kKM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to liftweb+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Antonio Salazar Cardozo

읽지 않음,
2016. 2. 4. 오후 1:13:2316. 2. 4.
받는사람 Lift
Maybe you can also attach a custom deserializer to the container and
use your own routine to build the object?
Thanks,
Antonio
To unsubscribe from this group and all its topics, send an email to liftweb+unsubscribe@googlegroups.com.

Joe Barnes

읽지 않음,
2016. 2. 4. 오후 5:37:0616. 2. 4.
받는사람 lif...@googlegroups.com
That's what we were thinking of doing, actually.  

Joe


Antonio
To unsubscribe from this group and all its topics, send an email to liftweb+u...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code

---
You received this message because you are subscribed to a topic in the Google Groups "Lift" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/liftweb/IyqS-w52kKM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to liftweb+u...@googlegroups.com.
전체답장
작성자에게 답글
전달
새 메시지 0개