HTTP/1.1 200
X-Application-Context: fss-proxy
Date: Tue, 03 Apr 2018 11:38:13 GMT
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Access-Control-Allow-Credentials: true
Access-Control-Allow-Methods: GET, POST, OPTIONS, PUT, DELETE, PATCH
Access-Control-Allow-Headers: Authorization,Content-Type,If-Modified-Since,headers,If-Modified-Since
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Connection: close
18
activeSessionsCount=1
0
我在这里有JSON。而且我想只获取当前字符串“activeSessionsCount = 1”中使用正则表达式时可能从0变为200或甚至更多的整数。可能吗?我完全被困在这里了。
答案 0 :(得分:0)
这取决于您用于正则表达式解析的语言 - 函数和方法会有所不同。 一般来说,它可以像/.* activeSessionsCount =(\ d +)/ gm
一样简单