Posts by Leonardo Ramos Duarte • 306 points
8 posts
-
1
votes2
answers382
viewsA: Extract values from a javascript string
How you work with a small string and have a pattern. can try using regex. qw=([A-Za-z0-9]+)&pag=([0-9]+) where what is in parentheses are the groups that are important to you. example of your…
-
10
votes5
answers4393
viewsA: Transforming a JSON information into a variable
I will try to write in a very didactic way, and not in a practical way. Json is a string, but if you assign a variable the same becomes an object, example: var informacoes = { "pair": "BTCBRL",…
-
0
votes3
answers210
viewsA: How would I look regex to handle this case?
If you need to separate by counting the letters: ([A-Za-z]{3})([a-zA-z]*) Will separate into two groups. Full match 0-10 CPFConsole Group 1. 0-3 CPF Group 2. 3-10 Console link If you need something…
-
1
votes1
answer81
viewsA: Play Framework running in production
play runs the process in fore-Ground so you need to run the . sh generated by Activator, with some program that monitors it... Two tips: 1 - Using linux systemd 2 - Use> superviser(extremely easy…
-
1
votes3
answers1511
viewsA: How to send an object via SOAP web service
You do not send the whole Person object, the best would be to create a serializer of the object. A SOAP message is nothing more than a STRING with an XML format following some different patterns.…
-
1
votes4
answers2799
viewsA: String reading with two or more names
you can use: fgets (nome, 15, stdin); or you can use the scanf even applying a regex that will eliminate a space, because if I remember well the scanf recognizes a space as a possible line break to…
-
2
votes2
answers358
viewsA: Ping on server with C#
There is the Ping class, example of use: public static bool pingServidor(string nameOrAddress) { bool pingable = false; Ping pinger = new Ping(); PingReply reply = pinger.Send(nameOrAddress); return…
-
0
votes1
answer92
viewsA: perform 2 methods that require audio reception
You need to run these two methods in separate threads, take a look at the internet about run/start threads for the language you’re using.