How to serialize and deserialize (marshal and unmarshal) JSON in .NET
JSON Parser in C#
Hi guys, I have a quick question about parsing a json file. Could someone explain to me about LEX/YACC, how can I think of it for a json file? Do I need to implement a lexical analyzer myself or are there standard libraries I can use? The programming language used is C#.
Best regards,
Sela
2 additional answers
Sort by: Most helpful
-
Bruce (SqlWork.com) 63,741 Reputation points
2022-01-23T16:51:38.943+00:00 There is also the popular newtonsoft library
https://www.newtonsoft.com/json
While you could write a json parser in lex/yacc, these are Unix tools and are not commonly used in the windows world. Actually ANTLR is more commonly used.
-
Limitless Technology 39,586 Reputation points
2022-01-24T15:18:24.857+00:00 Hello Sela,
I would recommend to check the next posts in MDSN Forum, as they contain recommendation for that kind of parsing tools:
https://social.msdn.microsoft.com/Forums/en-US/home?searchTerm=parser%20generator%20for%20C%23
--If the reply is helpful, please Upvote and Accept as answer--