开发者

Extract the text between the two substring in NSString

开发者 https://www.devze.com 2023-02-20 02:28 出处:网络
I need to extract the all the lines between two strings like开发者_如何学编程 Begin and End in the NSString.

I need to extract the all the lines between two strings like开发者_如何学编程 Begin and End in the NSString.

For example,

<some text>
Begin
line1
line2
End
<some Text>
Begin
line1
line2
End

I need to discard all the text that is not coming under these blocks. Any idea how to do this?


See -componentsSeparatedByString: in the NSString documentation.

0

精彩评论

暂无评论...
验证码 换一张
取 消